How To Find Windows Product Key – CMD & PowerShell

A Windows product key is a 25-character code that looks like XXXXX-XXXXX-XXXXX-XXXXX-XXXXX and is used to activate Windows.

This short note shows how to find the Windows product key from a command-line prompt (CMD) or from a Windows PowerShell and check its validity.

Cool Tip: How to check Windows version from CMD & PowerShell! Read more →

How To Find Windows Product Key

To find the Windows product key it is required to start the command-line prompt or the Windows PowerShell as an administrator.

Press ⊞ Win keybutton to open the Start menu, type in cmd to search for the command-line prompt or power to search for the PowerShell and press the Ctrl + Shift + Enter to launch it as an administrator.

Execute the command below in the elevated command-line prompt or the Windows PowerShell to display the Windows product key:

C:\> wmic path softwareLicensingService get OA3xOriginalProductKey

You can check the validity of the installed Windows product key by running this command from the command-line prompt or the Windows PowerShell:

C:\> slmgr /dli

If the license status is “Licensed”, then you are using the genuine Windows product key, otherwise the key is not genuine.

Leave a Reply