Windows 11 Shutdown Timer: How to Set It
In this article
Yes, you can set a shutdown timer on Windows 11 using the built-in shutdown command or Task Scheduler. The quickest way is to open Command Prompt and type shutdown /s /t 3600 to shut down in one hour. This guide walks you through every method, including how to cancel a timer, and works on all Windows 11 versions.
What You'll Need
- A Windows 11 PC or laptop
- Administrator access (not required for the basic timer, but needed for Task Scheduler method)
- No third-party software needed – everything is built into Windows
Step-by-Step
Method 1: Using Command Prompt (Quickest)
- Press Win + R to open the Run dialog.
- Type
cmdand press Enter. (You can also search “Command Prompt” in Start.) - In the Command Prompt window, type the following command and press Enter:
shutdown /s /t 3600
Replace 3600 with the number of seconds until shutdown. For example:
– 60 = 1 minute
– 600 = 10 minutes
– 3600 = 1 hour
– 7200 = 2 hours - You’ll see a system notification: “You’re about to be signed out. Windows will shut down in less than a minute.” This confirms the timer is set.
- To cancel the timer, type
shutdown /ain the same Command Prompt window and press Enter. You’ll see “Logoff is canceled” if successful.
Method 2: Using Run Dialog (No Command Window Needed)
- Press Win + R to open Run.
- Type the same command, e.g.,
shutdown /s /t 1800(30 minutes) and click OK. - A notification will appear confirming the shutdown.
- To cancel, open Run again (Win+R), type
shutdown /a, and press Enter.
Method 3: Using Task Scheduler (For Recurring or Specific Times)
- Press Win, type “Task Scheduler”, and open the app.
- In the right-hand pane, click Create Basic Task….
- Name it (e.g., “Shutdown Timer”) and click Next.
- Choose a trigger – for example, One time or Daily – and click Next.
- Set the start date and time, then click Next.
- Select Start a program and click Next.
- In the Program/script field, type
shutdown. - In the Add arguments field, type
/s /f(the/fforces running apps to close). Click Next. - Review the summary and click Finish.
- To test, right-click the task and select Run. To delete it, right-click and choose Delete.
Method 4: Create a Desktop Shortcut (One-Click Timer)
- Right-click on your desktop and select New > Shortcut.
- In the location field, type:
shutdown.exe /s /t 3600(adjust seconds as needed). - Click Next, name it (e.g., “Shutdown in 1 Hour”), and click Finish.
- Double-click the shortcut to start the timer. To cancel, create another shortcut with
shutdown.exe /a.
Common Mistakes
- Using the wrong time unit: The
/tparameter expects seconds, not minutes. Many people type 60 thinking it’s an hour – it’s actually one minute. - Forgetting the space before
/t: The command must beshutdown /s /t 3600– missing a space or using a slash incorrectly will cause an error. - Not using
/ato cancel: Closing the Command Prompt window does not cancel the timer. You must explicitly runshutdown /a. - Setting a timer while unsaved work is open: Windows will force-close apps if you add
/for if the timer expires without warning. Always save your work before the timer hits zero. - Using Task Scheduler without the
/sflag: If you forget/sin the arguments, the task will just log off instead of shutting down.
Tips
- Use
/fcarefully: Adding/fforces all open apps to close without saving. Only use it when you’re sure you don’t have unsaved work. - Set a reminder: Before setting a long timer, set a separate alarm to remind you to save your work a few minutes before shutdown.
- Use the notification area: When you set a timer, Windows shows a notification. If you miss it, you can check the exact shutdown time by typing
shutdown /?in Command Prompt – though it doesn’t show a countdown, only the command syntax. - Combine with sleep timer: If you want to sleep instead of shutdown, replace
/swith/h(hibernate) or userundll32.exe powrprof.dll,SetSuspendState 0,1,0for sleep. - Create a batch file: For multiple timers, create a .bat file with different commands and place it on your desktop for quick access.
Troubleshooting
Timer doesn’t start: Make sure you typed the command exactly. Check for typos like “shutdwon” or missing slashes. If using Task Scheduler, verify the task is enabled and the trigger time is correct.
“Access is denied” error: This usually happens when you don’t have administrative privileges. Right-click Command Prompt and select “Run as administrator”, then try again. For Task Scheduler, you must be logged in as an admin to create tasks.
Shutdown happens immediately instead of after the timer: This occurs if you forgot the /t parameter or used /t 0. Without /t, Windows shuts down after 30 seconds by default. Re-enter the command with a positive number.
Cancel command doesn’t work: The /a command only works if the timer hasn’t already reached the final minute. If you see “The system shutdown has already been initiated”, it’s too late – you can’t cancel. Also, you must run shutdown /a from the same user account that set the timer.
Timer works but PC restarts instead of shutting down: You may have typed /r instead of /s. Double-check your command. Also, some system updates may cause a restart after shutdown – that’s normal.
Task Scheduler task doesn’t run: Check the “Conditions” tab in the task properties. Uncheck “Start the task only if the computer is on AC power” if you’re on a laptop. Also ensure the task is set to “Run whether user is logged on or not” if you need it to run without login.
Frequently Asked Questions
Can I set a shutdown timer without typing commands?
Yes, you can use Task Scheduler or create a desktop shortcut with the command embedded. Both avoid typing the command each time.
What is the maximum time I can set?
There is no hard limit, but the /t value is in seconds and must be a 32-bit integer, so up to 2,147,483 seconds (about 68 years). In practice, use a reasonable number.
Will my unsaved work be lost?
If you don’t use /f, Windows will try to close apps gracefully, but it may still lose unsaved data if an app doesn’t respond. Always save your work before the timer expires.
Can I set a timer to restart instead of shutdown?
Yes, replace /s with /r in the command. For example: shutdown /r /t 3600 restarts after one hour.
Does the timer work if my PC is locked?
Yes, the shutdown timer runs in the background even if you lock the screen or log off. However, if you log off before the timer, the shutdown may be canceled.
Can I set a daily recurring shutdown?
Yes, use Task Scheduler and set the trigger to “Daily” with a specific time. The task will run every day at that time.