Subscribe to How-To Geek

Sync Your Clock With Internet Time Servers from the Vista Command Prompt

If you have an issue with your system clock losing time, you’ve probably had to go and re-sync your clock with the internet time servers. The problem is that there are just way too many clicks required to get to the right screen, so the command line is much simpler.

Note that you can partially solve this issue by changing the time server you are using or increasing the intervals between time checks, but there are some instances where you’ll just want to quickly sync the time manually.

Sync Clock the Slow GUI Way

First you’ll have to right-click on the clock and choose “Adjust Date/Time”

image

Then you select the Internet Time tab, and click the Change Settings button…

image

After the UAC prompt you can finally click the “Update now” button to tell the computer to resync.

image

That’s a lot of steps… but check out how simple it is from the command line.

Sync Clock from Command Line

Simply open an administrative mode command prompt (right-click, Run as administrator), and then type in the following command:

w32tm /resync

image

And now your clock is sync’d. If you want proof, you could check the time settings panel again.

image

Now that just seems easier to me.

The Geek is the founder of How-To Geek and a geek enthusiast. This article was written on 01/25/08 and tagged with: Vista Tips & Tweaks, Windows Vista

Daily Email Updates

You can get our how-to articles in your inbox each day for free. Just enter your name and email below:


Name:
Email:
Similar Articles Featured Wiki Articles
Latest Software Reviews Quick Linux Tips
Geek Arcade Popular Forum Threads

Comments (23)

  1. Butwheaty

    The command prompt option also works with Windows XP Professional.

  2. mgo

    nice tip! Thanks!

  3. Montana

    Thanks, this has saved me a lot of time…………..;)

    Montana

  4. teknikel

    I get: “The following error occurred:Access is denied. (0×80070005). any ideas?

  5. The Geek

    @teknikel

    You need to be using an administrative mode command prompt.

  6. Scott

    Yes, the cli is easier, but unless you have a cesium clock in your PC, you’ll have to do it again, and again as your clock skews. The GUI will keep your PC uptotime

  7. Mick

    @Scott

    You can put the command in a batch file and schedule it to run as often as you want.

  8. The Geek

    @Mick & Scott

    Windows automatically syncs your computer once a week if you have that option turned on. If that’s not often enough, you can adjust the interval: http://www.howtogeek.com/howto.....-problems/

    This command line option is most useful for when you need the clock to sync right now. For instance, I have a source control application I use at work that complains if my clock is more than a few seconds off.

  9. fb

    If your computer is on a domain then you don’t get that option. I think domain computer’s sync with the PDC so does anyone have any tips on how to setup time server syncing for the PDC?

  10. Blue Ridge

    To keep my computer’s time current, I use a utility called Dimension 4 from Thinking Man Software ( http://www.thinkman.com/dimension4/ ). It is much more flexible than Windows’ built-in Internet Time feature. As an added bonus, you can configure Dimension 4 to be an in-house time server (i.e., one computer [maybe the PDC] syncs with an Internet time server, and your internal computers sync with the Dimension 4 server). I’ve used this program for years, and I highly recommend it.

  11. John

    What to do if the 3rd tab “Internet Time” is missing?
    Is there anything to be done to “install” it?

  12. mark

    Thanks. For some reason even this command doesn’t sync with the internet time. Oh well, I’ll do it manually.

  13. snipefast

    the command line way does fix the error for synchronizing and if it asks you for administrator rights, close the command prompt and open it by right clicking on the command prompt icon in accessories and then click on run as administrator and then try the time sync command again and it should work.

  14. Rob

    Mine says

    the computer did not recognise the resync because the required time was too big….

    any help?

  15. john

    great idea, but what happens if you get “The following error occurred: Access is denied.

  16. john

    and running in admin mode I get “The computer did not resync because no time data was available”

  17. Jeremy

    I get the same as John, “The computer did not resync because no time data was available”

  18. peter

    If i go to Adjust date and time on my windows vista. then there is no internet time tab at all.
    so i can i sync my vista laptop with a internet time server ?

  19. Daniel Raiche

    In vista you can also setup your client time server using gpedit.msc – Administrative templates – system – Windows Time Service – Time Providers. You have the option to manually set the time provider like pool.ntp.org which seems to work the best, and even set the vista machine as a NTP provider for the rest of the network. Use C:\gpupdate /force after you make changes and test it out.

  20. Ambious

    Thank you!
    This helped me alot, I’m gonna create a batch file and schedule it to run every five minutes.
    Anyone have any idea why the phenomena of losing time happens in the first place?

  21. Abul

    I tried all suggestion given here and it seems like it does work…until i reboot my DELL inspiron 1525 laptop and the same problem will occur again and again. Does this problem has something got to do with game? FYI, I installed ONLY Football Manager 2008 weeks ago. But i only stucked in this problem few days ago (march 24, 2009).

    can anybody help?
    thank you.

  22. Flesz

    nice one

  23. nadia

    i have the problem of ‘access denied’ when i try the internet time synchronisation. and i think because of the i cannot log in on my msn live messenger! :( please help me solve the problem. i tried running the command prompt as an administrator (and anyway no one else uses my pc so i log in as an administrator anyway). it just says access denied. last nite it did not say ‘access denied’ it just said ‘an error occurred during synchronisation’ and i could log in on msn. but when it says ‘access denied’ i cant

    HELP!!!!!!!!!!!!!!!!!!!!!!!


Leave a Comment




Leave your friendly comment here.

If you have a computer help question, click here to leave it on the forums instead.

Note: Your comment may not show up immediately on the site.

Sponsored Links
Getting Started
About How-To Geek
What Is That Process?
svchost.exe
jusched.exe
dwm.exe
ctfmon.exe
wmpnetwk.exe
wmpnscfg.exe
rundll32.exe
wfcrun32.exe
Ipoint.exe
Itype.exe
Wfica32.exe
Mobsync.exe
Cmd.exe
Dpupdchk.exe Adobe_Updater.exe

Copyright © 2006-2009 HowToGeek.com. All Rights Reserved.