Share via

Shutdown/Restart Shortcuts

Reported
Anonymous
2019-02-15T02:16:52+00:00

Hello Microsoft Community,

I had seen online that you could add shortcuts to your desktop to quickly shut down or restart your PC. How can I do this but add a time interval (30 seconds, for example) before the computer shuts down or restarts? And is it possible to create a shortcut with the "shutdown -a" command in case I accidentally press the shut down or restart button?

Any help will be appreciated.

Thanks.

Windows for home | Windows 10 | Files, folders, and storage

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

6 answers

Sort by: Most helpful
  1. Anonymous
    2019-02-15T04:03:35+00:00

    Hi,

    Go to C:\Windows\System32\shutdown and create a shortcut...

    Select "Properties" of the shortcut and add the delay to the end of the shutdown.exe...

    It should look like this for a STANDARD Shutdown... NOT using the Fast Startup Feature...

    C:\Windows\System32\shutdown.exe -s -t 0

    The -s is for the shutdown... the -t is for the delay time..., and the 0 is for the time... you could use a 30 for 30 seconds for instance...

    The problem with this is that most all machines use a Fast Startup feature that needs a different command... C:\Windows\System32\shutdown.exe -s -hybrid -t 0...

    For a Restart shortcut again create a shortcut to C:\Windows\System32\shutdown and change to this...  C:\Windows\System32\shutdown.exe -r -t 0

    The -r is for the Restart instead of Shutdown... The rest is the same..

    You can also click on your Desktop, then press Alt+F4... This will bring up the Windows 7 style shutdown\restart\sleep\hibernate menu...

    I have a programmable button on my mouse that is set for "Close"... This "Close" generates a "Alt+F4" command on any window you click on before hitting the button, and closes it...

    This also brings up the Windows 7 style shutdown\restart menu...

    I personally prefer to use the Windows 7 style menu for a Shutdown, and my custom Restart shortcut to restart.. This guarantees that the Fast Startup feature will work properly...

    EDIT... Corrected the Restart command..

    0 comments No comments
  2. Sumit D - IA 166.2K Reputation points Independent Advisor
    2019-02-15T02:28:32+00:00

    Hi,

    I am Sumit, an Independent Advisor and a 2-Year Windows Insider MVP here to help.

    To shutdown the computer using command prompt and 30 second delay, use this command:

    shutdown /t 30

    0 comments No comments
  3. Anonymous
    2019-02-15T03:26:43+00:00

    Hi Sumit,

    I am trying to create a shortcut on my desktop to shutdown/restart my PC. How can I create a shortcut to do so? The command you provided is not working for me.

    Thanks.

    0 comments No comments
  4. Sumit D - IA 166.2K Reputation points Independent Advisor
    2019-02-15T02:46:32+00:00

    Are you running it from administrative command prompt?

    0 comments No comments
  5. Anonymous
    2019-02-15T02:44:36+00:00

    Hi Sumit,

    That command is not working for me. It is not shutting down the PC.

    Thanks.

    0 comments No comments