Find Your Windows 10 digital License/Product Key

Windows 10 is a versatile operating system that can be installed on almost any device: ranging from a desktop computer, to a tablet or a laptop.

It is important for your own safety that you have a valid and activated Windows 10 copy installed on your workstation. To check the product key status on your Windows 10 machine, you can go to Settings, select Update & Security and go to the Activation page. It should show something like the image below.

The Activation page in Windows Settings

As you can see from the image, I run Windows 10 Pro and it’s activation status reads:

Windows is activated with a digital license linked to your Microsoft account

But what is my Windows 10 product key? How to find out the currently installed license key of my Windows 10 installation? Where to find Windows 10 key? Maybe you want to backup the Windows 10 key just in case?

It turns out there is no easy answer to find this out. There is an option to change the product key in the Settings, but there is no such thing to show the active Windows 10 product key.

Microsoft’s website lists the following information about finding the Windows product key for Windows 10:

Where to find your product key depends on how you got your copy of Windows:
From an authorized retailer. The product key is on a label or card inside the box that Windows came in. For more info, contact your hardware manufacturer. 
A new PC running Windows. The product key is preinstalled on your PC, included with the packaging the PC came in, or included on the Certificate of Authenticity (COA) attached to the PC. For more info, contact your hardware manufacturer. 
A digital copy from a Microsoft website. The product key is in the confirmation email you received after buying your digital copy of Windows. If you bought Windows 10, you’ll receive a digital license instead of a product key. You can use the digital license for activation. For more info, see Activation in Windows 10 or contact Microsoft Support
Free upgrade to Windows 10. If you upgraded to Windows 10 for free from Windows 7 or Windows 8.1, you should have a digital license instead of a product key. For more info about digital licenses in Windows 10, see Activation in Windows 10 or contact Microsoft Support.

Excerpt from Microsoft support page

From the above information provided by Microsoft, for me it was still hard to know what exactly my 25 characters product key was that was currently being used on my legit Windows installation.

To uncover the current product key, you will need to create a vbs script. Go ahead and create an empty .vbs document on your desktop, for example: key.vbs. Open the empty file in Notepad and past the following text:

Set WshShell = CreateObject("WScript.Shell")
MsgBox ConvertToKey(WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\DigitalProductId"))

Function ConvertToKey(Key)
Const KeyOffset = 52
i = 28
Cur = 0
x = 14
Cur = Cur * 256
Cur = Key(x + KeyOffset) + Cur
Key(x + KeyOffset) = (Cur \ 24) And 255
Cur = Cur Mod 24
x = x -1
Loop While x >= 0
i = i -1
KeyOutput = Mid(Chars, Cur + 1, 1) & KeyOutput
If (((29 - i) Mod 6) = 0) And (i <> -1) Then
i = i -1
KeyOutput = "-" & KeyOutput
End If
Loop While i >= 0
ConvertToKey = KeyOutput
End Function

Save it as key.vbs and double click that file. Et voila, a small new window should open and display your product key! This should work also for Windows 10 Home, Windows 10 Pro, Windows 10 Education and Windows 10 Enterprise editions.

Your current Windows 10 (Pro) key


Author Bio

Thank you for your interest in my blog! On this miniblog, I write mostly short (technical) blog posts that might interest other people. Read more about me or feel free to contact me.


31 thoughts on “Find Your Windows 10 digital License/Product Key

    1. The script left out one of the registry keys that should go between current version and digitalproductId. This key is DefaultProductKey and there is also another key DefaultProductKey2. Insert one or the other to get a result other than BBBBB. However, none of the results seem to match what activation recognizes.

      1. Press Windows key + X
        Click Command Prompt (Admin)
        At the command prompt, type:
        wmic path SoftwareLicensingService get OA3xOriginalProductKey

  1. To activate Windows 10 you will follow this website. Here the writer of the blog discussed about steps to activate a Windows. If your Windows is not activated then you will follow the steps.

  2. ¡Brillante manera de descubrir el número de la licencia digital de Win 10! Funciona a la perfección. Este tío merece una medalla. ¡Muchisimas gracias desde España!

    (Maybe I can increase your blog readership by writing in Spanish).
    Brilliant way of finding out the digital license in Win 10! Works perfectly. This guy deserves a medal. Many thanks from Spain!

  3. Brilliant, worked like a dream. though i did have to then find out how to open a text file to create the vbs file as there was no such thing called notepad on mycomputer. it is amazing what you can find on the web. thanks for the script.

  4. I tried this on two different computers that were running Win7 OEM Dell Product Key. I used the MCT to upgrade to Win10. When using this script, both computers returned the same product key. Is that to be expected? The two computers are identical make/model. Thanks!

    1. Hello Frank
      Thanks for your comment.
      Actually that’s a good question – one for which I don’t have an answer.
      Likely explanation: all computers of the same make/model have the same windows key, as they are all licensed to use Windows. But, in that case, this specific key would only work on that specific make/model: not transfer possible.

      If someone has more info, I’d be interested to hear more about it.

      1. I might give that a try soon because i recently bought 2 identical systems. Maybe those have the same key as well. those are personal systems so those don’t get a key assigned from a license server. ill let you know.
        And thanks for the info to grab the license key :)

      2. I wonder if Microsoft changed Windows 10 so that this doesn’t work properly. I just activated a Dell laptop and used a manually entered product key. When running this script, the product key returned is NOT the one that was entered.

    1. Hi Seb
      Glad my blogpost could help you extract your Windows 10 product key – great to hear my method works and effective.
      Have a nice day!

      1. I have tried this on two separate pc’s – different machines that are completely unrelated – and I get an identical product key.
        Presume this is not expected. What is the issue

    1. Hi Lake
      thanks for the kind words – it may be even a bit exaggerated. But very happy this blogpost could help you find your Windows 10 key successfully.
      Have a nice day

  5. I had purchased a digital copy of Windows 10 Home and no longer had access to the original email with the digital license and this script was Godsend…Mr. Vanhoutte, thanks a ton for posting this, you rock!

  6. The key would not be accepted when I input it into the box requesting my product key when installing win10 from usb. Any suggestions?

  7. Worked with Win11 Pro, two different PCs. One home-built, with downloaded license, originally Win10 Pro, one an Asus laptop, also Win11 but originally Win10.

  8. This worked for me on two different systems. Question, I have just got a microsoft book 3 which has Windows 10 home plus an old laptop with the PRo version. If I get the key fro the PRO version will I be able to use this on the Surface Book 3?

Leave a Reply to Frank Cancel reply

Your email address will not be published. Required fields are marked *