Schedule Windows to Automatically Restart

How to schedule a Windows 98/2000/XP/2003 Computer to reboot.

This tutorial will show you how to schedule your PC to reboot at a given time and date, using the utility provided. This tutorial will work with Windows Server 2003, Windows XP, Windows 2000, and Windows 98. For this tutorial I will be using windows XP.

First Schedule Windows to Automatically Restart Download. Save it to disk and extract shutdown.exe to your C:\ drive.

Now open the Control Panel by clicking Start > Control Panel
Schedule Windows to Automatically Restart

In the Control Panel double click the Schedules Tasks (May be labeled Task Scheduler in other versions of windows) icon .
Schedule Windows to Automatically Restart

The Scheduled Tasks window should open up. Select Add Scheduled Task
Schedule Windows to Automatically Restart

This scheduled task wizard should open. Click next on the first screen.
Schedule Windows to Automatically Restart

Click browse and locate the shutdown.exe program. Select shutdown.exe and click open.
Schedule Windows to Automatically Restart

Select how often you would like to perform the task. I want my computer restart Weekly on Sunday morning, so I selected weekly. Make your select and click the next button.
Schedule Windows to Automatically Restart

Now select the time and the days of the week and click next. I selected 2am on every Monday.
Schedule Windows to Automatically Restart

On the next screen you will have to enter your password for windows. You must have a login password for these batch jobs to run. If you do not have a password you will need to add one in user settings. Enter your password information and click next.
Schedule Windows to Automatically Restart

On the final screen, put a checkmark the box that says “Open advanced properties for this task when I click Finish” and then click finish
Schedule Windows to Automatically Restart

Now we will see the advanced properties window.
Schedule Windows to Automatically Restart

Now we have to add a few arguments to the command in the run line. Add the –r –f –t 01 arguments to the line that exists in the run field. My line reads: “C:\SHUTDOWN.EXE –r –f –t 01”.
Schedule Windows to Automatically Restart

Then click apply and the task will be scheduled. You can check later in the task scheduler to see if the task ran successfully.
Schedule Windows to Automatically Restart

Subscribe To Our Newsletter

Subscribe To Our Newsletter

Join the TeamTutorials mailing list and get the latest tips, tricks, and special discounts for members only.

Thanks! Please click the link in the email we just sent you to confirm.

  • Partha

    Please explain the shutdown command parameters that you have used

  • Greg

    -r Shutdown and restart the computer

    -f Forces running applications to close without warning

    -t xx Set timeout for shutdown to xx seconds

  • Phillip

    Will this work for Vista? If not, how can you do this in Vista?

    • Kyle

      This will work for all windows based programs due to them being based off of the windows NT structure.

  • Thomas

    Will I need to make username/password in Windows 98 also?

  • Bjarne

    Thanks, works like a charm

  • Sharmatha

    Thankyou very much…this is very clear

  • Toddster

    Awesome program… now I have two additional exe files that I need to automatically run once the system reboots…..any idea how I can get them to run WITHOUT using the Start Up folder?

    Problem is that when I place in start up folder and log into server 2003 using RDP, everytime I log off and back on the processes duplicate or terminate…… I need the exe files to stay running until reboot. Any idea how to automate them on boot only?

    Thanks in advance…


  • Parvez

    Hi Todd.
    Make new string value and just add value(path of exe) in registry in local_machine/software/microsoft/windows/currentversion/run
    it will run when start ur computer

  • Lucifer

    My problem here is how do you get past the log in window after the comp booting windows after reboot? As you said the current user need a password on his account for this to work, but then when it try to boot up again you need to type the pass for it to login windows.

    Any idea how to make this go automatic?

    • Simple – tweakui can handle the auto log in.

  • Toddster

    Thanks again Parvez. All worked like a charm!


  • thales

    thank you man!!
    it rescued my life 🙂
    i’m searcinhg the web for a while to restart my computers , there were only “useless” programmes. but your one doesn’t require any software really, it uses Windows’ shutdown.exe

    thank you very much!

  • kijana

    I have the same problem. bypassing the log in window after the automatic reboot. does anyone have a clue on how to do this?

  • Joe

    To bypass the logon screen you can download the tweakui power toy from microsoft. Although I seem to be having a problem using this tool so perhaps they conflict. Certainly worth a try however.

  • If you don’t have a password set you can turn off the logon screen in windows xp.

  • Vincent

    This is the command line I am using. what is wrong when i right click on the task and click “run” to test it nothing happens except a Command prompt window briefly opens and shuts down. Computer does not shut down.

    C:\windows\system32\shutdown.exe -s -t 60 -c “Shutting down computer. School days ended. To remove with task open the Task Scheduler and delete task Weekly Shutdown” -f

  • Cage80

    Vincent, try using slashes ( /s /t) instead. I’m not sure yet if it’ll work, but that’s how it was told to do in shutdown’s help (shutdown.exe /? )

  • Dave

    Will this procedure work if I lock my PC? In other words, will the shutdown/restart work on a locked PC?

  • Aaron

    can you schedule a computer to bootup or start from the off position?

  • If your computer has “wake on LAN” capabilities it is probably possible to have another computer turn it on at a certain time. I don’t know how to do it off the top of my head.

  • Karon Walkner

    You can run an application as a service:

    I haven’t used it yet, since I do not have the need.

  • motie38

    The shutdown.exe is included in Windows XP in the windows\system32 folder. No need to download it.
    @ Dave Scheduled tasks work on a computer that is locked or logged off.
    @ Lucifer and kijana and Joe If you don’t have tweakui, you can still do automatic logon by editing the registry and adding these three string values in the following location, substituting the username and password to your actual ones.
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon]

    • Michael Tragarz

      Thanks for the info… worked like a charm……

  • Dan

    Aaron: You can schedule most PCs to startup at a certain time from the BIOS.

  • I’m running XP on a remote site serving a weather station on an island in northern Ontario Canada powered by a solar panel system. I would like to shut down the XPpc during the night and have it restart in the early morning. Can the shutdown.exe command include parameters to time the restart over greater periods of inactivity?
    I have remote access via which will allow a reboot but can not let me start a dormant machine.
    Any help wold be appreciated, reply here or to my email:
    -email removed. People have bots just looking for this stuff so that they can spam you. Leaving your email in the email field is good enough.-JW

    • Curt Wells


      I ran across your post dated, May 20, 2009 re shutting down XPpc during the night. I am trying to set up a similar remote system…solar panel and camera to monitor my remote ranch. I also need to shut down at night to conserve power. My system has been working well for a couple years with just network camera…now I would like to add a pc.

      I would greatly appreciate at it if you could tell me anything you learned on how to how to shutdown the pc at night and restart next day.

      – I have about given up on software based shutdown/restart..and plan to add relay/timer to the motherboard power-on connection.

      – Did logmein work ok for you? I am considering it as well as a package called Teamviewer.

      Curt Wells, Uhland, Texas

  • Dean, in theory you would need a network card that allowed wake-on-lan and an other device that could send the wake on lan signal. I’ve never tried it myself.

  • Matt Timken

    I would explore the idea of using a small UPS with a programmable interface (e.g. an APC Smart-UPS 1000) with an agent on the XP system.
    Set the UPS to shutdown the pc, then sleep for the required time, then restart. The XP system must be set to restart when power is applied (should be in the BIOS).

  • Hi there, thanks a million for this informative tutorial. The tutorial helped me improving my skills a little bit more. It is ever great to get some formidable inspiration and I hope to find more of such articles here the next time because no one will ever stop learning new things. Go ahead

  • Don

    The shutdown.exe file you hav available for download here will NOT work with W98 as it is specific to Win NT systems.

  • Pingback: auto reboot?()

  • It is jumping like dog
    And work more than fine

  • Dancingbear

    Works like a champ!
    Have not tested the auto password yet, but hope it works.
    I wonder if there is a way to make it instantly go to screensaver mode after login, so it loads all the stuff, but still needs a pw for anyone to actually get in. Is there an add-on string for that in shutdown.exe?

  • lonnieb

    Hi, is the process and download compatible with WinServer 2008?

  • Yogi Bear

    Thanks a lot. Wanted something that didn’t involve an installation and your solution has worked marvelously!

  • Cathy

    I receive an error when I try to do this: “0x80070005 access denied”. Using XP. Any advice?

  • Gautham

    when i tried to do this on my computer having xp sp2 its showing
    0×80070005 access is denied
    you do not have permission to perform this operation

  • Mike

    I’m sure you must have “Administrative Rights” to do this. Get the person who has those rights to do it.

  • Wes

    Can I set up to do this more than once a day?

  • dilak

    Hello ,

    I have set restart schedule in win XP

    (C:\Windows\system32\shutdown.exe -r-f-t 00)

    but one execution window (command line)pop up and go down at the mentioned time but system contnue running !

    please help

    • kalid

      Dear dilak

      use the following line

      C:\windows\system32\tsshutdn.exe 0 /delay:5 /reboot /v

      (it should work with 2000,xp.Not applicable for win7 )

    • Patrick Li


      I need to enter reason during reboot in Windows Server 2003, how can I put the parameters?

  • Nate

    Ok… I am trying to follow all this. I understand how to get it to shut down… How can i get it to shut down at say 3am.. then reboot (turn on) past login screen at say 6am?

    • Nate

      Or…. is there a way to set it to restart rather then shut down?

      • Nate

        NM… figured it all out 🙂

  • bong

    i know that procedure to scheduler but you demonstrate the shutdown.exe but i need a command line for automatic restart not for shutdown

  • If you need a program to restart, shutdown etc this program will do it all and it is free. Props go out to the author, I use this on fifty computers in my domain to do different tasks at any given time. Best little progy out there for what you are all looking for
    MCP, MCSA, MCSA:Security, MCSE, MCSE:Security, CompTia Security+

  • serg

    How LogonExpert does scheduled autologon and auto logoff

  • Pingback: scheduled task re-start of windows 2003 Server()

  • I am an Indonesian…
    this tutorial is so good…
    Very helpfully…

  • Anonymous

    Very Helpful.

  • ishtiin

    Well,Actually it could have been better

  • Joe Santos

    This tutorial is very well done. Thank you. However, I have two programs that are supposed to start but they are not, although they are included in the start up. They only start when I log in with logmein. Someone mentioned adding lines to the registry for programs to start up but I could not follow it. Hope you can help. Regards, Joe

  • Duane

    I have a Windows 2000 server with no shutdown.exe. where can I get this file or something else to work with 2000? going to use scheduled tasks to reboot once a month.

  • Never would have thunk I would find this so indipsenalsbe.

  • Mahesh


    Can we get alert or central monitoring after rebooting the server. we are restarting more than 100 servers but challanges are no central monitoring, no auditing alert, do not always works 100 %.

  • Your post is wonderful! 🙂 However, I thought it’s be easier to just located shutdown.exe in C:\Windows\system32 rather than download it. Just to point out.

  • very informative

  • Itsforme10,

    all OS related issue,please check the above link.

  • Muaaz

    Thanks Man…………………………

  • Doc Rabbitt

    it restarted to the log in screen hardly a useful reboot

  • Excellent site you’ve got here.. It’s hard to find high quality writing like yours nowadays.

    I seriously appreciate individuals like you! Take care!!

  • Pingback: Restart Cpanel Command Line()

  • Dragin XP forever

    IF you don’t have a password – because you only have one user and have managed to set that user up without a password – set the box that say something like “only run if logged on”. Since your system already comes up and logs in, this works 😀