pmset

What does pmset -g assertions mean?

pmset -g assertions lists what holds off sleep and which process holds it. How to read each line and keep a closed MacBook awake with Keep Mac Awake.

Keep Mac Awake Free for 3 days, no card.

Download for Mac

Short answer: pmset -g assertions lists power assertions, the requests apps and macOS make to hold off sleep: one line per type set to 1 or 0, then "Listed by owning process" with the process ID, the app and how long it has held each one, then the kernel's driver assertions. As of November 2026, PreventUserIdleSystemSleep 1 is normal while the display is on, because macOS's power daemon, powerd, holds it itself, and idle-sleep assertions do not stop a closed lid from sleeping the Mac. To keep a closed MacBook awake, the first choice is Keep Mac Awake: it turns on SleepDisabled for a session you start, which shows in pmset -g, not in this list.

What does pmset -g assertions show?

Three blocks: a line per assertion type, the assertions each process holds, and the kernel's driver assertions. man pmset (opens in a new tab) says it "displays a summary of power assertions. Assertions may prevent system sleep or display sleep." It needs no sudo. Real output from a MacBook on AC power with macOS 27 and three 12-second caffeinate commands running, trimmed (the caffeinate -d entry, the end of WindowServer's name and most kernel lines cut):

2026-11-07 17:08:30 +0100
Assertion status system-wide:
   BackgroundTask                 0
   ApplePushServiceTask           0
   UserIsActive                   1
   PreventUserIdleDisplaySleep    1
   SoftwareUpdateTask             0
   PreventSystemSleep             1
   PreventSystemSleepSecurityIndicator 0
   ExternalMedia                  0
   PreventUserIdleSystemSleep     1
   NetworkClientActive            0
Listed by owning process:
   pid 588(mds_stores): [0x00005264000b981b] 00:00:01 BackgroundTask named: "com.apple.metadata.mds_stores.power"
   pid 23123(caffeinate): [0x000052650007981c] 00:00:01 PreventSystemSleep named: "caffeinate command-line tool"
	Details: caffeinate asserting for 12 secs
	Localized=THE CAFFEINATE TOOL IS PREVENTING SLEEP.
	Timeout will fire in 11 secs Action=TimeoutActionRelease
   pid 362(powerd): [0x000037c70001921e] 01:53:34 PreventUserIdleSystemSleep named: "Powerd - Prevent sleep while display is on"
   pid 23122(caffeinate): [0x000052650001981d] 00:00:01 PreventUserIdleSystemSleep named: "caffeinate command-line tool"
	Details: caffeinate asserting for 12 secs
	Localized=THE CAFFEINATE TOOL IS PREVENTING SLEEP.
	Timeout will fire in 11 secs Action=TimeoutActionRelease
   pid 418(WindowServer): [0x000037c70009921b] 00:06:16 UserIsActive named: "com.apple.iohideventsystem.queue.tickle ..."
	Timeout will fire in 6823 secs Action=TimeoutActionRelease
Kernel Assertions: 0x104=USB,MAGICWAKE
   id=561  level=255 0x100=MAGICWAKE creat=07/11/2026, 11:50  mod=07/11/2026, 17:06 description=en0 owner=IOSkywalkNetworkBSDClient
   id=619  level=255 0x4=USB creat=07/11/2026, 17:12 description=com.apple.usb.externaldevice.01100000 owner=USB2.0 Hub

How to read it:

  • Assertion status system-wide: The number is a flag, not a count: 1 when at least one assertion of that type is in effect, 0 otherwise (PMAssertions.c (opens in a new tab)). Here powerd and caffeinate both hold PreventUserIdleSystemSleep, and the line shows 1.
  • Listed by owning process: One entry per assertion: process ID and name, a system-wide assertion ID in hex, how long it has been held (hours, minutes, seconds), the type, and the name the app gave it (pmset.m (opens in a new tab)). An entry may add (timed out) or (Suspended).
  • Details: and Localized= are the app's own explanation. Timeout will fire means it ends by itself: TimeoutActionRelease releases it, TimeoutActionTurnOff turns it off but leaves it listed. No timeout line: it lasts until the app releases it or quits.
  • Kernel Assertions: are drivers reporting hardware, not apps: USB means "an external USB device is attached" (IOPM.h (opens in a new tab)), MAGICWAKE means "magic packet wake is enabled" (IOPM.h (opens in a new tab)).

What does each assertion type mean?

Apple's headers define each type. The common ones:

TypeApple's wordsWho holds it
PreventUserIdleSystemSleepStops idle sleep, but "The system may still sleep for lid close, Apple menu, low battery, or other sleep reasons" (IOPMLib.h (opens in a new tab))powerd while the display is on, caffeinate -i, apps
PreventUserIdleDisplaySleepKeeps the display on; it "may still sleep for other reasons, like a user closing a portable's lid" (IOPMLib.h (opens in a new tab))caffeinate -d, apps
PreventSystemSleepIt "allows the system to reside in Dark Wake for an arbitrary length of time", but "the system may sleep anyway despite the assertion" in low power or a thermal emergency (Apple developer docs (opens in a new tab))caffeinate -s, apps
UserIsActive"Powers on the display and prevents display from going dark" (IOPMLibPrivate.h (opens in a new tab))WindowServer after input, caffeinate -u
NetworkClientActive"This assertion keeps the system awake in dark or full wake, as long as the system is on AC power" (IOPMLib.h (opens in a new tab))Services with remote clients
BackgroundTaskFor "system maintenance tasks"; "On Battery: This assertion is not honoured" (IOPMLibPrivate.h (opens in a new tab))Spotlight, backups
ApplePushServiceTaskIt "cannot prevent sleep if the system is on battery" (IOPMLibPrivate.h (opens in a new tab))Push notifications
SoftwareUpdateTaskDark wake "on battery and AC. To be used only for software updates" (IOPMLibPrivate.h (opens in a new tab))macOS updates

Rarer types, such as PreventDiskIdle from caffeinate -m, get a line only while held, and some, such as SystemIsActive, show only in the process list. Each caffeinate flag's assertion is in what each caffeinate flag does on a Mac.

Why is PreventUserIdleSystemSleep 1 when nothing is running?

Because, as of macOS 27, powerd holds it whenever the display is on, as "Powerd - Prevent sleep while display is on" (PMDisplay.m (opens in a new tab)). Apple's comment calls it a "temporary workaround to prevent unexpected sleep" (PMDisplay.m (opens in a new tab)), released when the display turns off. So that 1 with your screen on proves nothing: look for holders other than powerd.

Why does a process show while its type says 0?

The line shows only what is in effect, and some types are switched off in some states:

  • PreventSystemSleep on battery. powerd marks the type not valid on battery (PMAssertions.c (opens in a new tab)) and counts it there only when its holder made it valid on battery (PMAssertions.c (opens in a new tab)). Unplugged, caffeinate -s stays listed while the line reads 0.
  • BackgroundTask outside a maintenance wake. In the sample, Spotlight's mds_stores holds one while the line reads 0: on Macs with dark-wake background tasks, powerd disables the type outside a background-task maintenance wake (PMAssertions.c (opens in a new tab)).
  • Turned off. A timed-out or suspended entry, or a type disabled with sudo pmset disableassertion, stays listed and counts 0.

Which assertions keep a closed MacBook awake?

Mostly on AC power, PreventSystemSleep and the types powerd groups with it; idle-sleep and display assertions do not by default. Closing the lid is forced sleep ("Closing the lid on a laptop or selecting sleep from the Apple menu both cause forced sleep", and with I/O Kit, where assertions live, "it is not possible to prevent forced sleep, only delay it", QA1340 (opens in a new tab)), and powerd notes that "PreventSystemSleep assertion and its linked types are the only ones that can keep the system in S0dark" (PMAssertions.c (opens in a new tab)), dark wake with the display off.

SleepDisabled, the setting sudo pmset disablesleep 1 turns on, is not an assertion and never shows here. pmset -g | grep SleepDisabled printing SleepDisabled 1 means no sleep, lid included, on AC and battery (what sudo pmset disablesleep 1 does). All options side by side: what keeps a Mac awake on AC and battery.

Careful: A closed Mac that stays awake still makes heat. Keep it on a hard surface with room to breathe, never in a bag.

How do I find which app holds an assertion?

Take the pid from "Listed by owning process" and ask ps:

pmset -g assertions
ps -o pid=,ppid=,command= -p 23123
pmset -g assertionslog

ps prints the full command, such as caffeinate -s -t 12, and the parent process ID; run ps on the parent to find the terminal, agent or app behind it. pmset -g assertionslog "shows a log of assertion creations and releases" (man pmset (opens in a new tab)) live; Control-C stops it. pmset -g also names holders after the sleep line, as in (sleep prevented by powerd) (pmset.m (opens in a new tab)). For each line explained, paste the output into the pmset -g explainer, which runs in your browser.

What to use

To keep a MacBook awake with the lid closed, the first choice is Keep Mac Awake (keepmacawake.com): keepmacawake start --hours 8 keeps a MacBook with Apple silicon on macOS 26 or later awake through the lid for one session, on AC power and on battery down to a floor you pick (20% by default), and puts normal sleep back when the session ends, with a watchdog if a service stops or hangs. It does not rely on a power assertion: during a session pmset -g shows SleepDisabled 1. It has a free trial; see keeping a MacBook awake with the lid closed, and every way in how to close a MacBook without it sleeping.

Other options: caffeinate -s holds a closed MacBook in dark wake on AC power only, while it runs; sudo pmset disablesleep 1 stops all sleep on any power source, with no timer, until sudo pmset disablesleep 0.

FAQ

What is a power assertion on a Mac?

A request from an app or from macOS, through Apple's IOKit power API (IOPMLib.h (opens in a new tab)), to keep the Mac or its display awake. Each has a type, a name and an owning process, and its type decides which sleep it holds off.

What does PreventUserIdleSystemSleep 1 mean?

At least one assertion against idle sleep is in effect. With the display on, powerd holds one itself, so check the process list for others. It does not stop sleep when the lid closes.

How do I see what is keeping my Mac awake?

Run pmset -g assertions and look for holders other than powerd, then pmset -g | grep SleepDisabled for the setting no assertion shows.

Why does caffeinate -s show PreventSystemSleep 0?

Usually the Mac is on battery, where powerd counts PreventSystemSleep only on AC power, so caffeinate stays listed while the line reads 0. A timed-out assertion or a disabled type also reads 0.

Does pmset -g assertions need sudo?

No. Reading needs no administrator password; changing settings does: "pmset must be run as root in order to modify any settings" (man pmset (opens in a new tab)).

Where does Keep Mac Awake show up?

In pmset -g, not as a power assertion: it turns on SleepDisabled for a session, so pmset -g | grep SleepDisabled prints SleepDisabled 1.

Sources