PowerTip: Use PowerShell to Find Time Service Status


Summary: Use Windows PowerShell to find the status of the time service.

Hey, Scripting Guy! Question How can I use Windows PowerShell to find the status of the time service on my local computer?

Hey, Scripting Guy! Answer If all you are looking for is the status, use the W32tm command with the /query and /status switches:

w32tm /query /status

Comments (3)

  1. I wrote a powershell module around the w32tm command, it’s not perfect but has been handy.

    https://gallery.technet.microsoft.com/Windows-Time-Service-Module-65fcb82d

  2. Nick GW says:

    If you have Server 2003/XP around still, net time /query is the command you want. I believe /query was added to win32tm in Server2008 (yes, I’ve been debugging lots of time sync issues recently).

  3. Nick GW says:

    Sorry! Net time /querysntp

Skip to main content