Recover an Office 2016/2019 product key
You can't recover the full key from the machine. Only the last five characters are stored.
Answer
The full product key for volume or retail Office 2016/2019 can’t be recovered from the installed machine. Only the last five characters are stored.
What you can do
Check the license status and the last five characters:
cd "C:\Program Files\Microsoft Office\Office16"
cscript ospp.vbs /dstatus
(Use Program Files (x86) for 32-bit Office.)
Then match those five characters against:
- the Microsoft licensing portal (Volume Licensing Service Center / Microsoft 365 admin center for volume keys)
- the original deployment configuration or purchase records
Seeing this in your environment?
We can check for this, and everything around it, as part of an audit.