How do you find your Windows product key? That depends on how you got Windows. With a purchased key, it is in the confirmation email or in the retailer’s customer account. On a PC with preinstalled Windows, it is usually stored in the firmware and can be displayed with a PowerShell command. If Windows was activated through a free upgrade or purchased as an upgrade in the Microsoft Store app, there is no key but a digital license. In that case you do not need one for reinstalling on the same device either.
Quick decision
| How you got Windows | Where to find the key |
|---|---|
| Bought digitally from a retailer | Confirmation email or the retailer’s customer account |
| Bought as a box in a store | Label or card inside the box |
| New PC with preinstalled Windows | In the device’s firmware, on the packaging or on the Certificate of Authenticity (COA) |
| Bought online in the Microsoft Store | Confirmation email, order history of the Microsoft account |
| Free upgrade from Windows 10 | No key, but a digital license |
| Pro upgrade bought in the Microsoft Store app | No key, but a digital license on the Microsoft account |
| Refurbished PC | The refurbisher must supply the key |
By its own account, Microsoft only stores product keys if you bought online in the Microsoft Store. For all other purchases, the seller or the device manufacturer is the right contact.
Do you need the key at all?
Often not. If Windows is activated on the device, it has a digital license. According to Microsoft, you can reinstall the same edition on the same device without entering a key: in setup you select “I don’t have a product key”, and Windows then activates online.
You need the key if
- you activated Windows with a key and then replace the motherboard,
- you want to move the license to another PC, see Transfer a Windows license to a new PC,
- the activation state shows “not activated” after a reinstallation.
You can see the state under Start > Settings > System > Activation.
Option 1: Read the key from the firmware (PowerShell)
Many PCs with preinstalled Windows have the key stored in the firmware. Microsoft writes that setup applies it automatically if it matches the installed edition. This is how to display it:
- Right-click Start and select Terminal.
- Enter the following command and confirm with the Enter key:
(Get-CimInstance -ClassName SoftwareLicensingService).OA3xOriginalProductKey
- If a key with 25 characters appears, that is the key stored in the firmware at the factory.
- If the output stays empty, the command did not find a key in the firmware.
A note on the source: the WMI class SoftwareLicensingService is documented by Microsoft, but the property OA3xOriginalProductKey is not documented there. The command comes, in essence, from an independent advisor in the Microsoft Q&A forum; there are no instructions of Microsoft’s own for it. So compare the result with option 2.
Option 2: Display the last five characters (slmgr)
Windows does not display the installed key in full. With the script slmgr.vbs, however, you see the last five characters and can thus check which of your keys is installed.
- Press Windows key + R.
- Enter:
slmgr.vbs /dli
- The window shows the edition, the license status and the partial product key.
This command is more detailed:
slmgr.vbs /dlv
Compare the five characters with your records: with the retailer’s email, the sticker on the device or the output from option 1.
What no longer works: WMIC
Many older guides give this command for the Command Prompt:
wmic path softwarelicensingservice get OA3xOriginalProductKey
The WMIC tool has been deprecated since Windows 10, version 21H1. According to Microsoft, Windows 11 versions 24H2 and 25H2 have no longer included it since August 2026, and it cannot be reinstalled as an optional feature either. If your PC reports that wmic was not found, that is the reason. Use the PowerShell command from option 1 instead.
Registry and key finder programs
With slmgr.vbs /cpky, Microsoft provides a command that removes the product key from the registry so that malicious programs cannot steal it. We did not find a way to read the key from the registry in the Microsoft sources.
We cannot vouch for third-party key finder programs. If you use one, download it only from the publisher’s site and compare the result with the five characters from option 2.
Key from an order with us
You can find your key in three places:
- on the order confirmation page directly after paying,
- in the email sent to the address of your order,
- in your customer account under Orders, if you have created one.
Keep the email or write down the key. A key can usually be redeemed only once, and you may need it for a later reinstallation.
Typical cases
Laptop from the manufacturer, Windows is to be reinstalled. You do not need to read anything out. Setup applies the key from the firmware, or the digital license activates Windows online.
Self-built PC, key bought two years ago. If the PowerShell command returns nothing, look for the retailer’s email. With slmgr.vbs /dli you check by the last five characters whether you have found the right one.
PC brought to Windows 11 through the free upgrade. There is no separate key for Windows 11. Link the digital license to your Microsoft account, see
Activate Windows 11 with a product key.
Motherboard defective, key unknown. If the license was linked to your Microsoft account, the activation troubleshooter helps. With preinstalled Windows, according to Microsoft, a new license may be necessary after a motherboard replacement.
At VivaKeys
If no key can be found anymore and the PC needs a new license:
All versions are under Operating systems. Which edition fits is shown in the overview
Windows 11 editions at a glance. The differences between the types of keys are explained in
Retail or OEM: types of product keys.
Frequently asked questions
How can I read the Windows 11 product key with CMD? The formerly common command with wmic no longer works on current Windows 11 because Microsoft has removed the tool. In Terminal, use the PowerShell command
(Get-CimInstance -ClassName SoftwareLicensingService).OA3xOriginalProductKey. It shows the key from the firmware if one is stored there.
Can I read the Windows 11 key from the registry? We did not find a way described by Microsoft for this. The last five characters of the installed key are shown by slmgr.vbs /dli.
Why does PowerShell not show a key? Then the command did not find a key in the firmware. According to Microsoft, the key is stored in the firmware on many modern devices, but not on all. In this case, look for it in your purchase records.
Where should I look for the Windows key according to Microsoft? In the records of the purchase: confirmation email, box, Certificate of Authenticity, or with the device manufacturer. Microsoft does not name a program of its own for reading it out on its product key page.
Where do I find the key if I moved from Windows 10 to 11 for free? According to Microsoft, you have a digital license instead of a key. You do not need one for reinstalling on the same device.
How do I check whether the key from the firmware is the installed one? Compare its last five characters with the output of slmgr.vbs /dli. If they do not match, a different key is installed.
Sources
Checked on 2026-11-10 against the publisher’s information:
- support.microsoft.com/en-us/windows/activation/find-your-windows-product-key
- support.microsoft.com/en-us/windows/activation/activate-windows
- support.microsoft.com/en-us/windows/deployment/install-upgrade/create-installation-media-for-windows
- learn.microsoft.com/en-us/windows-server/get-started/activation-slmgr-vbs-options
- learn.microsoft.com/en-us/previous-versions/windows/desktop/sppwmi/softwarelicensingservice
- learn.microsoft.com/en-us/windows/win32/wmisdk/wmic
- support.microsoft.com/en-us/windows/activation/reactivating-windows-after-a-hardware-change
- learn.microsoft.com/en-us/answers/questions/3917670/powershell-windows-product-key-enigma