There are plenty of scripts available that promise to read the original Windows 10 product key from the registry by converting a series of binary values.
Unfortunately, most of the algorithms found in these scripts are deprecated, and the calculated product key is wrong. If you planned to reinstall the operating system, you may find out only after you erased your original installation.
A better and simpler way may be this one-liner:
PS> (Get-CimInstance -ClassName SoftwareLicensingService).OA3xOriginalProductKey
If it returns “nothing”, then your product key is not stored on the machine. Else, it is returned in its original form.