Or in case you don't want to install third-party applications just for grabbing your product key, here is a vb script. I used this script myself to borrow the genuine cdkey from my university computer and install win7 for upgrade to win10 so it works fine .
Spoiler:Set WshShell = CreateObject("WScript.Shell"
Set objFSO=CreateObject("Scripting.FileSystemObject"
outFile="key.txt"
Set objFile = objFSO.CreateTextFile(outFile,True)
objFile.Write ConvertToKey(WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\DigitalProductId") & vbCrLf
objFile.Close
MsgBox ConvertToKey(WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\DigitalProductId")
Function ConvertToKey(Key)
Const KeyOffset = 52
i = 28
Chars = "BCDFGHJKMPQRTVWXY2346789"
Do
Cur = 0
x = 14
Do
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
Should pop-up the windows produckt key and also save it in key.txt file. Open notepad and paste the above code then save as key.vbs or whatever you want to name it just be sure the extension is vbs and run. Works for Windows 7/10, haven't tested on 8 but it should work.
@Dwnld: You can use OEM media key as well with a slight trick. You are right it won't work if you're installing fresh windows from iso but you can still use it to activate your pirated windows (worked for me). See this
social.microsoft.com/Forums/en-US/ce677eb0-7d97-46d6-81df-a05dca1c2b85/change-product-key-windows-7?forum=genuinewindows7
[Edited by Kavvman, 8/13/2015 2:40:26 PM]