The fastest keyboard shortcut to shut down your computer
On Windows, press Alt + F4 while you are on the desktop (not inside an open program). A shutdown dialog box will appear with three options: Switch User, Sign Out, Shut Down, and Restart. Use the arrow keys to highlight Shut Down, then press Enter. Your computer will close all programs and power off.
On Mac, press Control + Command + Power (or Control + Command + Eject on older keyboards). A dialog will ask you to confirm. Press Enter to shut down when ready, or wait 60 seconds and it will shut down automatically. This method does not save open documents, so save your work first.
If Alt + F4 does not work on Windows, your computer may be inside a program window rather than on the desktop. Press the Windows key to return to the desktop, then try again.
Key Takeaways
- Windows users can shut down with Alt + F4 from the desktop, then arrow to Shut Down and press Enter.
- Mac users can shut down with Control + Command + Power, which triggers a 60-second countdown unless you confirm when ready.
- Both methods close all running programs, so save your work before you start the shutdown sequence.
- If a keyboard shortcut does not work, make sure you are on the desktop or home screen, not inside an open program.
Windows shutdown using the Run dialog
An alternative Windows method uses the Run dialog. Press Windows key + R to open the Run box. Type shutdown /s /t 0 and press Enter. The /s command shuts down, and /t 0 means shut down when ready with no delay.
If you want a delay before shutdown, change the 0 to a number of seconds. For example, shutdown /s /t 60 will shut down after 60 seconds, giving you time to save work or cancel. To cancel a shutdown that is already running, press Windows key + R again, type shutdown /a, and press Enter.
This method is useful if Alt + F4 is not responding or if you want to schedule a shutdown for a specific number of seconds from now.
Restarting instead of shutting down
If you need to restart rather than shut down, the keyboard shortcuts are similar. On Windows, press Alt + F4 from the desktop, arrow to Restart, and press Enter. On Mac, press Control + Command + Power, and when the dialog appears, press R for Restart.
Using the Run dialog on Windows, type shutdown /r /t 0 to restart when ready. The /r command restarts instead of shutting down. You can also add a delay the same way: shutdown /r /t 60 restarts after 60 seconds.
What to do if your keyboard shortcut is not working
If Alt + F4 does not open the shutdown dialog on Windows, check whether you are inside a full-screen program or game. Some programs override this shortcut. Press the Windows key or Escape to exit the program and return to the desktop, then try Alt + F4 again.
If you are already on the desktop and Alt + F4 still does not work, try the Run dialog method instead: Windows key + R, then type shutdown /s /t 0 and press Enter. This method works even when keyboard shortcuts are partially blocked.
On Mac, if Control + Command + Power does not work, your keyboard may not have a Power key. Try Control + Command + Eject instead, or use Control + Command + Q to quit the active program, then shut down through the Apple menu using arrow keys.
Shutting down a frozen or unresponsive computer
If your computer is frozen and keyboard shortcuts are not working, you may need to force a shutdown. On Windows, hold down the Power button on your computer case for 10 seconds until the screen goes black. This is a hard shutdown and can cause data loss, so use it only when the keyboard is completely unresponsive.
On Mac, press and hold the Power button for about 10 seconds until the screen goes dark. If that does not work, try pressing Command + Control + Power and holding it for several seconds, which forces a restart instead of a shutdown.
After a forced shutdown, your computer may take longer to start up the next time, as it will check the hard drive for errors. Avoid forced shutdowns when possible, since they do not let programs close properly.
Scheduling a shutdown for later
On Windows, you can schedule a shutdown to happen at a specific time using the Run dialog. Press Windows key + R, then type shutdown /s /t 3600 to shut down after 3600 seconds (one hour). Replace 3600 with the number of seconds you want to wait.
To see how much time is left before the scheduled shutdown, press Windows key + R again and type shutdown /t to check the countdown. If you change your mind, type shutdown /a to cancel the scheduled shutdown.
Mac does not have a built-in keyboard shortcut for scheduling a shutdown at a future time. You would need to use the System Preferences menu or a third-party scheduling tool.
Frequently Asked Questions
Will Alt + F4 close my open documents without saving?
Alt + F4 will close your computer, and any open documents that you have not saved will be lost. Most programs will ask you to save before closing, but some may not. Always save your work before using any shutdown command.
Can I shut down my computer if a program is frozen?
Yes. If one program is frozen but your keyboard is still responding, press Alt + Tab to switch to a different program or the desktop, then use Alt + F4 or the Run dialog to shut down. If the entire computer is frozen, hold the Power button for 10 seconds to force a shutdown.
What is the difference between shutdown and restart?
Shutdown powers off your computer completely. Restart powers off and then powers back on automatically. Use shutdown when you are done for the day, and restart when you want to clear the computer's memory or install updates.
Why does my Mac ask me to confirm the shutdown?
Mac shows a confirmation dialog to prevent accidental shutdowns. You can press Enter to confirm when ready, or wait 60 seconds and it will shut down on its own. If you want to cancel, press Escape or click Cancel.
Can I shut down a Windows computer remotely using the keyboard?
Not with a local keyboard shortcut. If you need to shut down a Windows computer remotely, you would need to use Remote Desktop or a network command, which is beyond keyboard shortcuts on the local machine.