S

How to Remove an Old or Cracked Microsoft Office Product Key via CMD

333 views · updated 2026-07-02 · published 2026-07-02 · Microsoft Office Reading time: 2 min English සිංහල

If Windows shows an old, duplicate, or previously-used (cracked) Microsoft Office product key, you can remove it from the command line before entering your new genuine key. This works for Microsoft Office 2010 through 2024 (one-time purchase / perpetual editions).

Part 1: Check the Office license status

Open Command Prompt as administrator and change into your Office program folder with cd. The path depends on your Office version:

Office 2016 / 2019 / 2021 / 2024 (64-bit):

cd C:\Program Files\Microsoft Office\Office16

Office 2016 / 2019 / 2021 / 2024 (32-bit):

cd C:\Program Files (x86)\Microsoft Office\Office16

Note: “Office16” is the folder name for Office 2016–2024. For Office 2013 use Office15, and for Office 2010 use Office14.

Now check the current license status:

cscript ospp.vbs /dstatus

This lists any installed product keys along with the last 5 characters of each key.

Part 2: Remove the existing / cracked product key

Use the /unpkey switch with the last five characters of the key you want to remove (from the /dstatus output):

cscript ospp.vbs /unpkey:XXXXX

Replace XXXXX with the last five characters of the product key. This removes that activation key from your system. If more than one key is listed, repeat the command for each key you want to remove.

Part 3: Activate with your genuine key

Once the old key is removed, open any Office app (Word, Excel, etc.), go to File → Account, choose Change Product Key, and enter the new 25-character product key we sent you. Office will then activate as genuine.

Notes

  • Always run Command Prompt as administrator, or the commands will fail.
  • If ospp.vbs is not found, make sure you are in the correct Office folder (Office14 / Office15 / Office16).
  • Removing the key does not uninstall Office — it only clears the activation so you can enter a fresh key.

Thanks for your feedback! 🙌

Read more

📖

Office Home & Business 2024 vs Office Professional Plus 2024 LTSC — Key Differences

Apps included, Mac support, activation method, update channel and ideal users — how Office Home & Business 202

📖

Understanding Microsoft Office Versions and Editions

Make sense of one-time-purchase Office (2019/2021/2024) versus Microsoft 365 subscriptions, and the editions w

📖

Office Home & Business 2024 සහ Office Professional Plus 2024 LTSC අතර වෙනස

ලැබෙන apps, Mac support, activation ක්‍රමය, update channel එක සහ ගැළපෙන user වර්ග — Office 2024 editions දෙක අ

📖

Get Free Office Apps

How to Get Microsoft Office Apps (Word, Excel, PowerPoint) for Free Use the free Office web and mobile apps, p

📖

Office 2021 Home & Business for Mac — Download, Install & Activation Guide

Redeem your Office 2021 Home & Business key at setup.office.com, download the Mac installer, activate by signi

Add Office Language Packs

Overview Office language accessory packs let you use the interface, help, and proofing tools in additional lan

📖

Disable Office Automatic Updates

How to Disable Automatic Updates in Microsoft Office Turn off Office auto-updates via the built-in option or t

📖

Office 2021 Home & Business for Mac — Download, Install සහ Activate කරන හැටි (සිංහල)

setup.office.com එකේ Office 2021 key එක redeem කරන හැටි, Mac installer එක download කරන හැටි, sign-in එකෙන් act