Remove old licenses from Office

Sometimes it may already happen that after installing your new Office, it is still indicated that an older Office is installed. For example, you installed Office 2024 but your File - account still shows Office 2021 or Office 2019.
This means that there are still small remnants of your previous Office application. You can solve this simply :

Solution 1 :

Use the office uninstall tool to be sure to remove all old remnants of Office : https://aka.ms/SaRA-officeUninstallFromPC
If you did this before installing Office then you may go to solution 2.

Solution 2 :

Open Word. Click on file - Account and at the top left you are logged in. Click log out here. Close Word and restart Word again. Go again to file - account and on the right of the screen choose change product code (if it asks for an account to log in do not do this but click on the link below it "I have a product code" and enter the license code you got from us.

Solution 3 : 

Close all your Office applications.

Using explorer, go to "c:program data" and delete all the files that are in this directory

(Possibly in your case, the folder program data is hidden. Then click on "view" at the top of your explorer and then "show hidden items")

Restart word : you will be asked to log in or you can choose to enter product key. Do not log in but then re-enter the key and your identification will normally be correct as Office 2024.

Solution 4 :

Please note these steps are not for beginners and require some technical knowledge / understanding. Everything is entirely at your own risk and we cannot provide any support in this regard either.

That said let's get right to work.

Step 1: open command prompt and run control script

  • Open command prompt as administrator(start type in cm and then right click run as administrator.
  • With cmd open, you can run the script below to see what product codes are installed on your system

For 64-bit Office : cscript "%ProgramFiles%Microsoft Office%office.vbs"/dstatus

For 32 bits Office : cscript "%ProgramFiles(x86)% Microsoft Office" /dstatus

A little note: You see Office16 in this example. That stands for Office 2016/2019. If you have an older version then you choose Office 2013 Office15 and Office 2010 Office 14

You will then get a screen like this:

Importantly, there may be multiple codes installed in your situation(for the same product). Write down only the last 5 characters you WANT to remove.

Step 2: Actually deleting the product key

Do you have the last 5 characters? Then we can actually remove the code now

We do this with the script below:

cscript "%ProgramFiles%Microsoft Office.vbs"/unpkey:xxxxx

Or if you get an error message:

cscript "%ProgramFiles(x86)%Microsoft Office.vbs"/unpkey:xxxxx

Obviously, the xxxxx are the last 5 characters of the product code you want to delete.

As it was in our case: cscript "%ProgramFiles(x86)%Microsoft Office.vbs"/unpkey:jfjdp

Step 3: It remains Microsoft so always reboot just to be sure

Yes this title says it all, always reboot. I was given this as a tip when a Microsoft employee after hours of searching still had not succeeded in clearing the system of a product key.

And that was basically it.

Briefly:

  • Open cmd(command prompt) as administrator
  • Run the script to see what codes are on your system.
  • Verify the last 5 characters match the code you want to delete
  • Run the script to remove the code and done.