Guides

How to Uninstall Windows Product Key (Before Selling Your PC)

By Super AdminPublished Aug 28, 2026Updated Aug 28, 20261 min read

Direct Answer

Before selling or transferring a PC, deactivate your Windows key with "slmgr /upk" so you can reuse a retail license or protect it. Here is how to properly remove your product key.

Key Takeaways

Before selling or transferring a PC, deactivate your Windows key with "slmgr /upk" so you can reuse a retail license or protect it. Here is how to properly remove your product key.

How to Uninstall a Windows Product Key: The Direct Answer

To remove a Windows product key, open an admin Command Prompt and run slmgr /upk to deactivate, then slmgr /cpky to clear the key from the registry. Do this before selling a PC (to protect or reuse a retail key) or before transferring a retail license to a new machine.

When You Should Remove Your Key

Two main scenarios: you are selling or giving away the PC and want to protect your retail key from misuse, or you are transferring a retail license to a new computer. In both cases, deactivating on the old machine first is the correct step.

Step-by-Step: Removing the Key

  • Open Command Prompt as administrator (right-click > Run as administrator)
  • Run slmgr /upk and press Enter — this uninstalls the product key
  • Run slmgr /cpky and press Enter — this clears the key from the registry
  • Restart the PC — Windows is now deactivated

Retail vs OEM: What You Can Transfer

Only retail licenses can move to a new PC. If your key is retail, deactivate it on the old machine and activate it on the new one. OEM keys are permanently tied to the original motherboard and cannot be transferred — check your license type with slmgr /dli first.

Before Selling Your PC

Deactivating Windows is only part of preparing a PC for sale. You should also back up your files, then reset the PC (Settings > System > Recovery > Reset PC) to wipe your personal data. This protects both your license and your privacy.

The Bottom Line

Remove your product key with slmgr /upk and slmgr /cpky before selling or transferring. Retail keys can then be reused on a new PC. If you need a fresh genuine key, see the product below.

Frequently Asked Questions

FAQ

How do I remove my Windows product key from a PC?

Open an admin Command Prompt and run "slmgr /upk" to uninstall the product key, then "slmgr /cpky" to clear it from the registry. This deactivates Windows on that machine.

Should I remove my Windows key before selling my PC?

Yes, if you have a retail license you want to reuse, or to protect your key from being used by the new owner. OEM keys cannot be transferred and stay with the hardware.

Can I reuse my Windows key on a new PC after removing it?

Yes, if it is a retail license. Deactivate it on the old PC with "slmgr /upk", then activate it on the new one. OEM keys cannot be transferred to a new PC.

What is the difference between slmgr /upk and /cpky?

"slmgr /upk" uninstalls the product key and deactivates Windows. "slmgr /cpky" clears the key from the registry so it cannot be recovered. Run both when transferring or selling.

Does removing the product key delete my files?

No. Removing the product key only deactivates Windows — your files and apps remain. If selling the PC, you should also reset or wipe the drive separately to remove personal data.

Related Products

Windows 11 Pro - Lifetime
Best Seller-95%

Software

Windows 11 Pro - Lifetime

Genuine Windows 11 Pro OEM license key, lifetime.

LifetimeLicense Key
$10.99$199.99
Microsoft 365 Personal - Lifetime
Best Seller-71%

Software

Microsoft 365 Personal - Lifetime

Word, Excel, PowerPoint, 1TB OneDrive — genuine license.

LifetimeSubscription Key
$19.99$69.99

Related Articles