If you have a keyboard with an eject key, you can use ⌃⌥⌘ (control-option-command-eject).

If you have a laptop with a power key in place of an eject key, the power key can be substituted for eject in OS X v10.8 (Mountain Lion) and newer versions of OS X.

Other keyboard shortcuts:

  • ⌃⌘ restarts the computer
  • ⌥⌘ puts the computer to sleep
  • ⌃⇧ puts displays to sleep
  • ⌃ opens the dialog shown when pressing a power button or power key
  • ⇧⌘Q logs out after showing a confirmation dialog
  • ⌥⇧⌘Q logs out without showing a confirmation dialog

My keyboard doesn't have an eject or power key, so I normally use Alfred:

You could also assign a keyboard shortcut to a script like this:

tell app "System Events" to shut down

The shut down command sends loginwindow a kAEShutDown Apple event, which starts a normal shut down sequence as described in the Daemons and Services Programming Guide. sudo shutdown -h now does not for example allow graphical applications to ask for confirmation if there are unsaved changes.

Answer from Lri on Stack Exchange
🌐
Reddit
reddit.com › r/macos › shutdown from keyboard
r/MacOS on Reddit: Shutdown from keyboard
January 13, 2023 -

I've read in numerous places that it's possible to shut down your Mac by holding down Ctrl/Option/Cmd and the power button. However, for me, it just signs me out.

Does this shortcut no longer work or is it only certain devices?

I have a MacBook Pro 13 with Touch Bar and running Ventura 13.1

Top answer
1 of 4
4

If you have a keyboard with an eject key, you can use ⌃⌥⌘ (control-option-command-eject).

If you have a laptop with a power key in place of an eject key, the power key can be substituted for eject in OS X v10.8 (Mountain Lion) and newer versions of OS X.

Other keyboard shortcuts:

  • ⌃⌘ restarts the computer
  • ⌥⌘ puts the computer to sleep
  • ⌃⇧ puts displays to sleep
  • ⌃ opens the dialog shown when pressing a power button or power key
  • ⇧⌘Q logs out after showing a confirmation dialog
  • ⌥⇧⌘Q logs out without showing a confirmation dialog

My keyboard doesn't have an eject or power key, so I normally use Alfred:

You could also assign a keyboard shortcut to a script like this:

tell app "System Events" to shut down

The shut down command sends loginwindow a kAEShutDown Apple event, which starts a normal shut down sequence as described in the Daemons and Services Programming Guide. sudo shutdown -h now does not for example allow graphical applications to ask for confirmation if there are unsaved changes.

2 of 4
7

Well, while it's not "keyboard only" per se, you can open up a terminal and type in sudo shutdown -h now, which will send a signal to the kernel to shutdown the computer.

I'm not sure if that was exactly what you were looking for, but it should be a viable solution.

Apparently, another option is to use Command-Option-Control-Media Eject key, which will quit all applications and let you save documents/work and then shuts down the mac.

Discussions

What is "shutdown your mac" keyboard shor… - Apple Community
Control–Option–Command–Power button* or Control–Option–Command–Media Eject : Quit all apps, then shut down your Mac. If any open documents have unsaved changes, you will be asked whether you want to save them. ... So what is the keyboard shortcut for it? Other than Apple Menu > Shutdown. More on discussions.apple.com
🌐 discussions.apple.com
macos - shortcut keys for shutdown, sleep and restart for mac - Stack Overflow
I am using mac laptop first time and I habituated with windows shortcuts. So tried to find the shortcuts for mac too but didn't got. So anyone please tell me What are the shortcut keys for shutdown, More on stackoverflow.com
🌐 stackoverflow.com
How to set up a keyboard shortcut for "Shut Down..."? | MacRumors Forums
I've just bought the new MacBook Pro (Apple M2 Max, 2023 running Ventura 13.4 and can't see to work out how to do it. This official instruction does not work (see screenshot) Is there a way to program a keyboard shortcut to quit all apps and shut down the computer? Thanks so much! Nik ... As above: set a keyboard shortcut. "Shut Down..." will prompt to shutdown ... More on forums.macrumors.com
🌐 forums.macrumors.com
May 29, 2023
Automatically Shutdown Mac
I would love this as well. Why is it so intentionally difficult to programmatically shut down a Mac? More on reddit.com
🌐 r/shortcuts
4
6
March 4, 2023
🌐
Logitech
logitech.com › logitech united states › discover › keyboard shortcut for shutdown: mac & windows | logitech
Keyboard Shortcut for Shutdown: Mac & Windows | Logitech
For those with Intel based Mac ... commands. Depending on your Mac model, you can follow these steps. ... Control + Option + Command + Power/Eject: This keyboard shortcut for shutdown works on Intel based Mac comput...
🌐
DEV Community
dev.to › davidkou › shortcut-keys-to-shut-down-mac-macbook-pro-mini--g1
Shortcut keys to shut down Mac (MacBook Pro, Mini ...) - DEV Community
March 26, 2022 - If you google it, you will find that you can shut down Mac Using Keyboard Shortcut(key combination) as shown below:
🌐
LinkedIn
linkedin.com › pulse › mac-keyboard-shortcuts-sleep-log-out-shut-down-arvind-kumar
Mac Keyboard Shortcuts for Sleep, log out, and shut down shortcuts
February 19, 2023 - Option–Command–Power button or Option–Command–Media Eject : Put your Mac to sleep.
Find elsewhere
🌐
TechPP
techpp.com › how-to guides › mac › shut down, sleep, or restart mac using keyboard shortcuts
Shut Down, Sleep, or Restart Mac Using Keyboard Shortcuts
January 3, 2024 - Master the art of controlling your Mac effortlessly with keyboard shortcuts. Learn how to shut down, sleep, or restart your Mac with just a few keystrokes.
🌐
iOS Hacker
ioshacker.com › home › how to shutdown, restart, sleep or log out on mac with keyboard shortcuts only
How To Shutdown, Restart, Sleep Or Log Out On Mac With Keyboard Shortcuts Only - iOS Hacker
April 3, 2024 - This dialog will ask if you want to restart, shut down, or put the Mac to sleep. You can also access the dialog box quickly by pressing Control + Power buttons (Eject button on Macs with optical drive). Command + Control + Power Button: Press this keyboard shortcut to force restart your Mac.
🌐
Apple Support
support.apple.com › en-us › 102650
Mac keyboard shortcuts - Apple Support
2 weeks ago - Fn-D: Start or stop dictation. You may be able to set a different dictation shortcut in Keyboard settings. Fn-N: Show or hide Notification Center. Fn-Shift-A: Show or hide Apps (macOS Tahoe 26 or later) or Launchpad (earlier versions of macOS).
🌐
Wccftech
wccftech.com › home › mobile › sleep, shut down, restart your mac using keyboard shortcuts [how to]
Sleep, Shut Down, Restart Your Mac Using Keyboard Shortcuts [How to]
March 15, 2021 - You can use keyboard shortcuts to put your Mac to sleep, shut down or even restart. These shortcuts work on all versions of macOS.
🌐
SlashGear
slashgear.com › 1648182 › restart-shutdown-macbook-keyboard-shortcuts
How To Restart Or Shut Down A MacBook Using Keyboard Shortcuts - SlashGear
August 26, 2024 - Keep in mind that forcefully shutting down your Mac should be a last resort, as it will cause you to lose any unsaved data. In the past, keyboard shortcuts like Control + Power or Control + Media Eject would display a dialog prompting you to restart, sleep, or shut down your Mac.
🌐
Apple Community
discussions.apple.com › thread › 254582370
What is "shutdown your mac" keyboard shor… - Apple Community
Control–Option–Command–Power button* or Control–Option–Command–Media Eject : Quit all apps, then shut down your Mac. If any open documents have unsaved changes, you will be asked whether you want to save them. ... So what is the keyboard shortcut for it? Other than Apple Menu > Shutdown.
🌐
Stack Overflow
stackoverflow.com › questions › 47467054 › shortcut-keys-for-shutdown-sleep-and-restart-for-mac
macos - shortcut keys for shutdown, sleep and restart for mac - Stack Overflow
I am using mac laptop first time and I habituated with windows shortcuts. So tried to find the shortcuts for mac too but didn't got. So anyone please tell me What are the shortcut keys for shutdown, sleep and restart for mac-airbook laptops.This is my laptop keyboard image
🌐
AppleToolBox
appletoolbox.com › home › changing mac keyboard shortcuts for shutdown
Changing Mac Keyboard Shortcuts for Shutdown - AppleToolBox
2 weeks ago - Hold down the Power button to shutdown the computer. Press and hold the Power again. Let go when the computer starts to reboot and immediately hold down Shift. Open the Apple menu on your Mac computer.
🌐
Alphr
alphr.com › home › how to shut down a mac with the keyboard
How To Shut Down a Mac With the Keyboard
May 25, 2022 - The following shortcut will quit all apps and ask whether you need to save any work before shutting down: “Control” +”Option” + “Command” + Power button · Next up, we have a few tips you can try if your Mac computer won’t turn off.
🌐
MacBook Journal
macbookjournal.com › how-to-shut-down-macbook
How to Shut Down MacBook: 3 Quick Ways
November 21, 2021 - To safely shut down your Mac, press Control ^+ Option ⌥ + Command ⌘ + Power/Touch ID. Don’t hold down the Power button alone, as it will force a shutdown.
🌐
MacRumors
forums.macrumors.com › macs › macos › macos ventura (13)
How to set up a keyboard shortcut for "Shut Down..."? | MacRumors Forums
May 29, 2023 - I've just bought the new MacBook Pro (Apple M2 Max, 2023 running Ventura 13.4 and can't see to work out how to do it. This official instruction does not work (see screenshot) Is there a way to program a keyboard shortcut to quit all apps and shut down the computer? Thanks so much! Nik ... As above: set a keyboard shortcut. "Shut Down..." will prompt to shutdown "Shut Down" will shut down immediately.
🌐
Reddit
reddit.com › r/shortcuts › automatically shutdown mac
r/shortcuts on Reddit: Automatically Shutdown Mac
March 4, 2023 -

Hi, I found the shortcut depicted below in a post on an AppleInsider blog. The intent of the shortcut is to close all applications. I have incorporated the shortcut and placed it on my dock. I initiate the shortcut right before I shut down my computer. My problem is that after invoking the shortcut, I still have to access the apple menu to initiate the shutdown.

My question is: is there a way to append the shortcut below to quit all applications and automatically shut down the computer as well?

  • Open Shortcuts on your Mac

  • Click the Plus icon in the upper right of the application to create a new Shortcut

  • In the Search Bar on the right side of the screen, type in "Quit"

  • Select "Quit App" under the Scripting section from the search results

  • When the action gets added, select "App" from within the action prompt

  • Select "All Apps" from the menu

  • Choose if you want any apps to stay open when closing others by clicking on the "Except" text of the Shortcut

  • Name your Shortcut and give it an icon to identify it by

  • Close the Shortcut by clicking on the red traffic icon

🌐
Quora
quora.com › How-can-I-create-a-keyboard-shortcut-in-preferences-to-shut-down-my-Mac
How to create a keyboard shortcut in preferences to shut down my Mac - Quora
Answer (1 of 3): As Callidus Auctor has already explained, you can use the Power button to do this. But if you use a MacBook in clamshell mode with an external keyboard, you don’t have easy access to the Power button. To create a keyboard shortcut to make it sleep (you could use the same method ...