Free tool

What does pmset -g mean? Mac sleep settings explained

Paste pmset -g and see what each Mac sleep setting means, which one keeps a closed MacBook awake and what to fix. Nothing leaves your browser.

Short answer: pmset -g prints the power settings your Mac uses right now, one per line: a setting's name, then its value, where 0 usually means off or never. Only one line decides whether a MacBook stays awake with the lid closed: SleepDisabled 1 under "System-wide power settings" turns all sleep off, lid included, until it is set back to 0. sleep 0 and the apps listed in "(sleep prevented by ...)" only stop idle sleep while the lid is open. To keep a MacBook awake with the lid closed for a set time, the first choice is Keep Mac Awake: it turns SleepDisabled on for one session you start and puts normal sleep back afterwards.

Download for MacFree for 3 days, no card. Then $9 once.

How do I read pmset -g?

Run pmset -g in Terminal; it only reads, so it needs no sudo. It "will display the settings currently in use" (man pmset), in up to two groups:

pmset -g
# System-wide power settings:
#  SleepDisabled    0
# Currently in use:
#  sleep                0 (sleep prevented by caffeinate)
#  displaysleep         10
#  ...
  • System-wide power settings apply whatever the power source. SleepDisabled lives here; no SleepDisabled line means it was never set, which is normal sleep.
  • Currently in use are the settings for the power source the Mac runs on now. pmset -g custom prints them for each source, under "Battery Power" and "AC Power".
  • Timers are in minutes, and 0 means never: "Use a minutes argument of 0 to set the idle time to never for sleep disksleep and displaysleep" (man pmset).
  • A note after a timer, such as (sleep prevented by caffeinate), names the apps holding power assertions right now. pmset -g assertions lists them in detail.

What does each pmset -g setting mean?

Each line in the order people ask about it. Apple's man pmset describes most of them; where it does not, the table says so.

SettingWhat it meansKeeps a closed MacBook awake
SleepDisabledA system-wide switch: 1 turns all sleep off, lid included, on AC power and on battery, until sudo pmset disablesleep 0. Not in man pmset; Apple's pmset source defines itYes, when 1
sleep"system sleep timer (value in minutes, or 0 to disable)": idle sleep onlyNo, not even at 0
displaysleep"display sleep timer": the screen only, so a dark screen is not a sleeping MacNo
disksleep"disk spindown timer"No
standbyHibernates the Mac "after it has slept for a specified time period" to save power while asleepNo
powernapPower Nap: a sleeping Mac "activates periodically to update information" (Apple Support)No
womp"wake on ethernet magic packet", the same as Wake for network accessNo
tcpkeepaliveNot in man pmset. Set to 0, Apple's pmset warns that "some critical features like 'Find My Mac'" will not work properly during sleepNo
hibernatemodeHow the Mac sleeps: 3 (portable default) keeps memory powered with a copy on disk, 0 (desktop default) keeps no copy, 25 hibernates. "Please use caution"No
hibernatefileWhere the hibernation image goes, on the root volume onlyNo
ttyskeepawakeStops idle sleep while a terminal or remote login session is activeNo, idle sleep only
lowpowermodeLow Power Mode, which "reduces energy use to increase battery life" (Apple Support). Not in man pmsetNo
powermodeOn Macs with High Power Mode instead of lowpowermode: 0 neither, 1 Low Power Mode, 2 High Power Mode (Apple's pmset source)No
networkoversleepHow shared network services appear during sleep; "changing its value is unsupported"No
lidwake, acwakeWake when the lid opens, or when the power source changesNo
autopoweroff, standbydelayhigh, standbydelaylowWhen a sleeping Mac writes its hibernation image and powers down furtherNo
Sleep On Power ButtonNot described in man pmset or Apple's documentationApple does not say

What does pmset -g assertions mean?

An assertion is a request an app or macOS makes to delay sleep. pmset -g assertions shows each type with 1 (someone holds it now) or 0, then "Listed by owning process" with the app, how long it has held it, and its name. Apple's headers describe the common types:

AssertionWhat it meansKeeps a closed MacBook awake
PreventUserIdleSystemSleepStops idle sleep; "The system may still sleep for lid close, Apple menu, low battery, or other sleep reasons." caffeinate holds it by defaultNo
PreventUserIdleDisplaySleepKeeps the display on, and so stops idle sleep; "the display may still sleep for other reasons, like a user closing a portable's lid"No
PreventSystemSleepcaffeinate -s holds it, and it "is valid only when system is running on AC power" (man caffeinate)No
NoIdleSleepAssertionThe old name of PreventUserIdleSystemSleep, deprecated since Mac OS X 10.7; some apps still use itNo
UserIsActiveSomeone used the Mac: it turns the display on and postpones display sleep, then times outNo
BackgroundTask, ApplePushServiceTaskmacOS maintenance work, such as backups and Spotlight indexing, and push notifications; on battery, Apple's source says, BackgroundTask is not honouredNo
NetworkClientActiveKeeps the Mac awake while it serves network clients, on AC power; Apple calls it "a suggestion"No

The "Kernel Assertions" line is drivers reporting hardware to power management, such as MAGICWAKE (magic packet wake is on) or USB (an external USB device is attached), per Apple's IOPM.h. Why no caffeinate flag gets past the lid is in why caffeinate does not keep a MacBook awake with the lid closed.

Which pmset values keep a closed MacBook awake?

Only SleepDisabled 1. Closing the lid is a forced sleep, separate from the idle timer: "Closing the lid on a laptop or selecting sleep from the Apple menu both cause forced sleep" (QA1340). So sleep 0, displaysleep 0 and every assertion an app holds leave a closed MacBook to sleep. Apple's other exception is closed-display mode, which needs an external display, power, a keyboard and a mouse (Apple Support).

To keep a MacBook awake with the lid closed and no display, the first choice is Keep Mac Awake (keepmacawake.com): keepmacawake start --hours 8 turns SleepDisabled on for one session on a MacBook with Apple silicon and macOS 26 or later, a watchdog restores normal sleep if anything stops or hangs, and a timed session ends on time. Other options: sudo pmset disablesleep 1 does the same switch with no timer or watchdog and stays on, even after a restart, until sudo pmset disablesleep 0; closed-display mode ties the Mac to a desk. More on how to keep a MacBook awake with the lid closed.

Which pmset settings are risky?

Three are worth a second look.

  • SleepDisabled 1 left on. The Mac no longer sleeps when you close it, so it keeps running in a bag and on battery. If no Keep Mac Awake session or other tool you trust is running, undo it with sudo pmset disablesleep 0, as what sudo pmset disablesleep 1 does explains. If your MacBook stays awake after you close it, see MacBook not sleeping when the lid is closed.
  • A changed hibernatemode. man pmset lists 0, 3 and 25 and says "Please use caution". 3 is the default on portables.
  • tcpkeepalive 0. Apple's own pmset warns that Find My Mac may not work properly while the Mac sleeps.

Careful: A closed MacBook that is awake still makes heat. Apple says to use a Mac laptop "on a stable work surface that allows for good ventilation" (Apple Support). Never leave an awake Mac in a bag.

Is it safe to paste my pmset output here?

Yes. The explainer runs entirely in your browser: the page sends what you paste nowhere, stores nothing, and keeps it out of the site's analytics. Where the site's analytics run, they count that the tool was used, never what you pasted. pmset -g holds power settings and, in the assertions, the names of the apps holding them; read it before you paste it anywhere else.

If your Mac still goes to sleep when you do not expect it, MacBook shuts down when the lid closes? How to fix it shows how to read the reason with pmset -g log.

FAQ

What does pmset -g do?

It prints the power settings your Mac uses right now: the sleep timers, SleepDisabled, hibernation, Power Nap and more. It only reads and needs no sudo.

What does sleep 0 mean in pmset?

The idle sleep timer is off: the Mac does not sleep from inactivity. It still sleeps when you close the lid, because that is a forced sleep the timer does not cover.

What does "sleep prevented by" mean in pmset -g?

The apps named there hold power assertions that stop idle sleep right now. Run pmset -g assertions to see which assertion each one holds. Apple says the Mac may still sleep when the lid closes while they are held.

What does SleepDisabled 1 mean?

All sleep is off, closing the lid included, until sudo pmset disablesleep 0. During a Keep Mac Awake session that is expected, and the session puts 0 back when it ends.

What is hibernatemode 3?

The default on Mac laptops: a copy of memory goes to disk while memory stays powered, so the Mac wakes from memory unless it lost power (man pmset).

Sources