The fastest keyboard shortcut to shut down your computer
On Windows, press Alt + F4 while you are on the desktop (not inside any open program). A dialog box will appear asking whether you want to shut down, restart, or sign out. Use the arrow keys to select "Shut down" and press Enter.
On Mac, press Command + Q to close the active window, then press Command + Control + Eject (or Command + Control + Power on newer models) to shut down when ready without a confirmation dialog. If you want a confirmation dialog first, use Command + Shift + Q to sign out, then restart or shut down from the login screen.
On Linux, the method depends on your desktop environment. In GNOME, press Alt + F2, type poweroff, and press Enter. In KDE Plasma, press Alt + F2, type shutdown -h now, and press Enter. Different distributions may vary slightly.
Key Takeaways
- Windows users can press Alt + F4 on the desktop to open a shutdown dialog, then select shutdown with arrow keys and Enter.
- Mac users can press Command + Control + Eject to shut down when ready, or Command + Shift + Q to sign out first.
- Linux shutdown commands vary by desktop environment but typically involve Alt + F2 followed by typing a shutdown command.
- If Alt + F4 does not work on Windows, your active window may be a full-screen program; press Escape first to return to the desktop.
- You can also use the Windows Start menu with keyboard navigation: press the Windows key, then press the right arrow to reach the power menu.
Windows shutdown using the Start menu
If Alt + F4 does not work, you can navigate through the Start menu instead. Press the Windows key (the key with the Windows logo) to open the Start menu. Then press the right arrow key repeatedly until you reach the power button icon in the bottom right corner of the menu.
Once the power button is highlighted, press Enter to open the power options. Use the arrow keys to select "Shut down" and press Enter again. This route takes longer than Alt + F4 but works reliably on all Windows versions.
What to do if Alt + F4 closes a program instead
Alt + F4 closes whatever window is currently active. If you are inside a program like a web browser or text editor, Alt + F4 will close that program, not shut down your computer. Press Escape or click the desktop first to make sure no program window is selected, then try Alt + F4 again.
You can also minimize all open windows by pressing Windows key + D on Windows, or Command + F3 on Mac, which clears the desktop and ensures Alt + F4 targets the system instead of a program.
Restarting instead of shutting down
On Windows, press Alt + F4 on the desktop, then use the arrow keys to select "Restart" instead of "Shut down" before pressing Enter. On Mac, press Command + Control + Power and hold it until you see the restart confirmation, or use Control + Command + Eject and select restart from the dialog.
On Linux in GNOME, press Alt + F2, type reboot, and press Enter. In KDE Plasma, type shutdown -r now instead of poweroff.
Signing out without shutting down
If you want to sign out of your user account but leave the computer running, press Alt + F4 on Windows and select "Sign out," or press Command + Shift + Q on Mac. On Linux, the sign-out command varies by desktop environment but is usually found in the system menu accessible through Alt + F2.
Signing out closes all your open programs and returns the computer to the login screen, which is useful if you share the computer with other users or want to lock your account without powering down.
Forcing a shutdown if the keyboard shortcuts do not respond
If your keyboard shortcuts are not working, your computer may be frozen or unresponsive. On Windows, try pressing Ctrl + Alt + Delete to open the security screen, then select "Sign out" or "Shut down" from the bottom right corner. On Mac, press Command + Option + Esc to open the Force Quit dialog, close any frozen programs, then use Command + Control + Power to shut down.
If keyboard commands fail completely, hold down the physical power button on your computer for 10 seconds until it powers off. This is a last resort because it can cause data loss or file corruption, but it works when nothing else does.
Frequently Asked Questions
Why does Alt + F4 not work on my Windows computer?
Alt + F4 closes the active window, so if a program is open, it closes that program instead of shutting down the system. Click on an empty area of the desktop first, or press Windows key + D to minimize all windows, then try Alt + F4 again.
Can I schedule a shutdown for a specific time using the keyboard?
On Windows, press Windows key + R, type shutdown -s -t 3600 (where 3600 is the number of seconds), and press Enter. On Mac and Linux, use the terminal with commands like shutdown -h +60 to shut down in 60 minutes. The exact syntax varies by operating system.
What is the difference between shutdown and restart?
Shutdown powers off your computer completely. Restart powers it off and when ready turns it back on, which is useful for installing updates or fixing problems. Both can be done with keyboard shortcuts from the shutdown dialog.
Is it safe to use the keyboard shortcut instead of the normal shutdown menu?
Yes, keyboard shortcuts like Alt + F4 trigger the same shutdown process as clicking the power menu. Your computer will close programs and save data the same way. The only exception is holding the power button, which forces an when ready shutdown without saving.