You might need to use cscript commands to activate Office if you are unable to activate it through usual means, for example, in the following situations:

  • Every time you open an Office application, it prompts you to sign in to your Microsoft account to activate Office;
  • Upon each startup, Office applications require a license key and continue to display a pop-up 'Product still requires activation, and the most features will be disabled by xx/xx/xxxx' after the correct license key is added.

Cscript commands which are run using the Command Prompt or Windows Powershell allow to remove old cached keys and correctly activate Office with a new product key. To activate Office with cscript command follow these steps:

  1. Open Command Prompt with administrative permissions: go to Start> type 'cmd' > right-click Command Prompt and select Run as administrator.
    Tip: You can also use Windows Powershell instead of the Command Prompt. Regedit
  2. Execute the command corresponding to your Office version:
    • Office 2010: cd C:\Program Files (x86)\Microsoft Office\Office14
    • Office 2013: cd C:\Program Files (x86)\Microsoft Office\Office15
    • Office 2016 and Office 365: cd C:\Program Files (x86)\Microsoft Office\Office16

      Note: The path indicated above may vary between Program Files and Program Files (x86) directories depending on your installation. Follow this path on your machine to confirm where Office is installed.

  3. View the installed product keys by executing cscript ospp.vbs /dstatus. Each license is displayed in a separate block containing detailed information, including the last five characters of the key. Regedit
  4. Uninstall the product keys by running cscript ospp.vbs /unpkey:XXXXX. Replace the XXXXX with the last five characters of the installed keys found in Step 3.
    Note: You will need to run one command for each key that needs to be uninstalled.
  5. Run cscript ospp.vbs /dstatus to make sure all keys were uninstalled. Regedit
  6. To activate Office:
    • If you are using a product key, execute cscript ospp.vbs /inpkey:XXXXX-XXXXX-XXXXX-XXXXX-XXXXX (replace XXXXX with your fill product key for Office) to install a new product key and run cscript ospp.vbs /act to activate Office with the new product key.
    • Open an Office application and sign in to our Office account or enter the product key when prompted.
      Office Apps Installation Instructions and Sign In/Out Process for instructions on how to install and activate Office Apps.