This tutorial covers everything on how to get or recover the product key of Windows 8 (8.1) version. Users can also approach another way of getting Windows 8 (8.1) Product Key by using few third party software like Belarc Advisor. We have done a video showing step by step procedure on how to find Windows 8 Product Key on a Preinstalled OS using a Software. Learning new things will always upgrade current knowledge. So, try out this method of extracting Windows 8 (8.1) Product Key without using any software.
How to Find Windows 8.1 Product Key
To explain better, we are splitting this tutorial into 3 steps. Let’s begin the work. 😉
Step 1: Get the right PowerShell Script
In this step, the user needs to collect some script or code from the Microsoft Technet website. We also provided the script here, but keep an eye on Microsoft Technet website if it doesn’t work for you (they updates the code). Here is the script,
function Get-WindowsKey {
## function to retrieve the Windows Product Key from any PC
param ($targets = ".")
$hklm = 2147483650
$regPath = "Software\Microsoft\Windows NT\CurrentVersion"
$regValue = "DigitalProductId64"
Foreach ($target in $targets) {
$productKey = $null
$win32os = $null
$wmi = [WMIClass]"\\$target\root\default:stdRegProv"
$data = $wmi.GetBinaryValue($hklm,$regPath,$regValue)
$binArray = ($data.uValue)[52..66]
$charsArray = "B","C","D","F","G","H","J","K","M","P","Q","R","T","V","W","X","Y","2","3","4","6","7","8","9"
## decrypt base24 encoded binary data
For ($i = 24; $i -ge 0; $i--) {
$k = 0
For ($j = 14; $j -ge 0; $j--) {
$k = $k * 256 -bxor $binArray[$j]
$binArray[$j] = [math]::truncate($k / 24)
$k = $k {c7b30aa9d9592c4bbf2e2941f10032306801ed79863eb96c896f90a2ea2e1931} 24
}
$productKey = $charsArray[$k] + $productKey
If (($i {c7b30aa9d9592c4bbf2e2941f10032306801ed79863eb96c896f90a2ea2e1931} 5 -eq 0) -and ($i -ne 0)) {
$productKey = "-" + $productKey
}
}
$win32os = Get-WmiObject Win32_OperatingSystem -computer $target
$obj = New-Object Object
$obj | Add-Member Noteproperty Computer -value $target
$obj | Add-Member Noteproperty Caption -value $win32os.Caption
$obj | Add-Member Noteproperty CSDVersion -value $win32os.CSDVersion
$obj | Add-Member Noteproperty OSArch -value $win32os.OSArchitecture
$obj | Add-Member Noteproperty BuildNumber -value $win32os.BuildNumber
$obj | Add-Member Noteproperty RegisteredTo -value $win32os.RegisteredUser
$obj | Add-Member Noteproperty ProductID -value $win32os.SerialNumber
$obj | Add-Member Noteproperty ProductKey -value $productkey
$obj
}
}
Get-WindowsKey
Get-WindowsKey localhost
Copy the above code and open Notepad then paste the script exactly. Now save the file with name “RecoverKey.ps1“.
Step 2: Run the Saved PowerShell Script
Here comes the second step.
Now open Windows PowerShell by going to Windows Metro Style dashboard (Press Windows button) and search for “PowerShell“. Right click on the application then selects “Run as Administrator“. Hit “Yes” when you prompted with UAC dialog box.
Step 3: Finally, find the Windows 8.1 Product Key
Final step. The user needs to type a couple of commands here. Here you go.
Firstly type the following command on PowerShell
Set-ExecutionPolicy RemoteSigned
Type “Y” when it displays “Do you want to change the execution policy” message.
Next, type the second command and hit Enter to extract Pre Installed Product key of Windows 8 Operating System
Import-Module PATH; Get-WindowsKey
How to Get Path of PowerShell Script file?
Right, click on RecoverKey.ps1 file. Move to Properties then switch to “Security” tab. Copy the Object Name path and paste it into PowerShell.
[Updated] If it returns an error like showing product key as “BBBBB-BBBBB-BBBBB-BBBBB” then follow these updated methods to find Windows 8 Product Key on Preloaded Laptop.
second step is not working
Can you please elaborate your problem.
It shows as BBBBB-BBBBB-BBBBB-BBBBB for me when I try this. Can you please explain what to do in this case…
Are you using genuine version?
Hi, I got the same BBBB issue. I assume my version is genuine. It is the version that came with the computer, which I bought in an authorized store. Any suggestions will be appreciated. Thanks
Hi There,
I am using a original, genuine and it still show the BBBB…
Sorry for that. We are drafting a new article where you can extract the product key within seconds. Stay tuned!
thanks in advance, now my windows 8.1 is activated
hi
thanks very much, i had really struggled to activate windows 8.1 pro, but after following your steps, i managed to activate it without any hassles. thanks you very much this was really helpful
it really working
can’t find Volume key
i changed my windows 7 64bit to windows 8.1 pro build 9600 i have tried to activate it but the last stage of the command is not bring out any result please sir i need help.
You must run the Command Prompt in Administrative privileges.
What is producer for Command Prompt
hi Sai Praveen , I am using windows8 pro build 9200 and third step is not working, it says,
Import-Module : A positional parameter cannot be found that accepts argument ‘saini\Desktop\RecoverKey.ps1’.
etc…. Plz reply soon
You must run the Command Prompt in Administrative privileges.
hi there. Can i do this tutorial even in my laptop running windows 8.1 that is not came preinstalled in windows 8.1 pro? i’ve lost my case and i wonder if i can also do this same thing. thank you.
You can do. But if you believe that the OS installed is genuine, then you will get the product key. Otherwise, it will return you all BBBBB’s
third step is not working for me pls give any sugestions for that
Try now!
The problem is there are missing “\” in some of the commands in the script such as the line:
$regPath = “SoftwareMicrosoftWindows NTCurrentVersion”
where it should be
$regPath = “Software\Microsoft\Windows NT\CurrentVersion”
just buy it
from windows store
Fixed. Thank you 🙂
my windows is not genuine how do i get product key?
thanks .
Sir i tried it and i got the key by ur method . But even that product key is not working.What could be the problem?.mine is windows8,1 pr0
I’ve tried this entire process and I got a product key. However, upon trying to enter the Key in PC Settings, it gives an error:
This key didn’t work, please check it and try again, or try a different key
the second part of the third step is not working!!!
I also tried it but is bring another thing which i don’t understand
hey does this work win 10
Hi Pravin,Good job man just script need to be updated in the above code as ” ” ” is replaced with ",please make the changes,thanks
Fixed Mr. Ravish. Thanks for letting us know 🙂
i tried this,script ran successfully but still m not able to activate windows with the provided key,please help