slmgr Command Reference: Check Windows Activation Status Correctly

A reference for the slmgr commands that actually matter when diagnosing Windows activation: /xpr, /dlv, /dli, /ato, /upk and /rearm, with how to read their output.

Why slmgr is the only answer that counts

Settings shows a friendly sentence. slmgr shows the licence. When an activation script, a KMS host or a digital licence disagrees with what Windows displays in the UI, the Software Licensing Management tool is what support threads will ask you for.

Run everything below from an elevated Command Prompt or PowerShell.

The commands worth knowing

slmgr /xpr

The fastest sanity check. It answers a single question: is this machine permanently activated, activated until a date, or not activated at all. If a method claims success and /xpr says notification mode, the method did not take effect.

slmgr /dli

A short summary: partial product key, licence status and, for KMS-based activation, the remaining grace period in minutes.

slmgr /dlv

The verbose version. This is the output to capture before asking for help. It includes the activation ID, the licence channel (Retail, OEM, Volume:MAK, Volume:GVLK), the KMS machine name if one is set, and the renewal interval.

The channel line is the single most useful field. It tells you whether the system is even eligible for the method you are attempting — a Retail channel installation will not respond to KMS the way a GVLK installation does.

slmgr /ato

Forces an activation attempt. Useful after fixing network or time-sync problems, because Windows will otherwise wait for its own schedule.

slmgr /upk and /cpky

/upk uninstalls the current product key; /cpky clears it from the registry. These are cleanup commands, not fixes. Running them casually on a machine with a legitimate retail key can leave you needing that key again.

slmgr /rearm

Resets the licensing evaluation period where the edition supports it. Limited number of uses, and not a substitute for actual activation.

slmgr /skms and /ckms

Set or clear the KMS host the machine points to. A stale /skms value left behind by an old tool is a very common cause of activation failures that look mysterious.

Reading the output like a diagnostician

Symptom in outputUsual meaning
Licence Status: NotificationNot activated; the grace period ended
Volume:GVLK channelEligible for KMS-style activation
Retail channelExpect a digital licence or product key path instead
Non-zero error code near 0xC004…Look the code up before retrying anything
KMS machine name set to an unfamiliar hostA previous tool left a configuration behind

Office is a different tool

slmgr does not report Office. For Office, open the Office installation folder and run:

cscript ospp.vbs /dstatus

That prints the licence name, the last five characters of the installed key, and the remaining grace period per product.

Before you post an error anywhere

Collect three things: the output of slmgr /dlv, the exact error code, and the Windows edition and build (winver). Threads that include those three are answered quickly; threads that say "activation not working" are not.

For method-specific behaviour, read the upstream notes rather than second-hand summaries.


massgrave.download is an independent documentation and troubleshooting resource. It is not the official Massgrave project. The official project lives at massgrave.dev and github.com/massgravel.

Get MAS from the official project

This site does not host its own build of the scripts. The buttons below go to the project’s own repository and mirrors, so what you get is what the developers published.

PowerShell one-liner published by the project:

irm get.activated.win | iex

Check the domain before running it, and see how to verify what you run.

Activation tooling is routinely classified as riskware by antivirus software. That is expected for this category and is not by itself evidence of malware — nor proof that a particular copy is clean. Verify the source before running anything.