The helper
Open Terminal (Command-Space, type Terminal), paste this command, and press Return. Then select all of what it prints and paste it below.
pmset -g assertionsIf the Mac sleeps and then wakes, paste this morning’s log instead or as well
This answers a different question: what woke the Mac, not what held it awake. Run one of these in Terminal and paste the output:
pmset -g log | grep -e " Sleep " -e " Wake "pmset -g log | grep -i "wake reason"For the whole overnight story, see MacBook battery drain overnight on macOS 27.
Common reasons a Mac won’t sleep
- A video call or meeting app, sometimes even after the call has ended.
- Music or video playing, including a browser tab.
- A download, sync or backup still running.
caffeinate, a command that keeps a Mac awake. Scripts and apps use it, and it’s easy to forget one running in Terminal; see how to keep your Mac awake.- Sharing and network settings. Screen Sharing, File Sharing or Wake for network access can keep a Mac awake or wake it.
- Its own settings. On a desktop Mac, check System Settings ▸ Energy; on a laptop, System Settings ▸ Battery ▸ Options, for Prevent automatic sleeping settings.
To see the same thing without Terminal, open Activity Monitor, click Energy, and sort by the Preventing Sleep column. If your battery itself is the worry, try the battery health calculator or read how to check battery health. Apps made to keep a Mac awake, such as Amphetamine, show up here too.
Questions
What does pmset -g assertions show?
A summary of power assertions, which may prevent system sleep or display sleep, then each process holding one, with how long it has held it and the reason it gave. PreventUserIdleSystemSleep 1 means something is keeping the Mac awake; PreventUserIdleDisplaySleep 1 means something is keeping the display on.
Is it bad if my Mac doesn’t sleep?
Not for the Mac: macOS and its hardware are made to run for days. It costs power, and on a laptop it costs battery and warmth in a bag. An app that keeps the Mac awake when you didn’t want it to is worth finding.
Why does my Mac wake up at night?
Usually because something asked it to: another device reaching it over the network, a Bluetooth keyboard or mouse, or scheduled maintenance. Run pmset -g log | grep -i "wake reason" in the morning, or paste that output in the optional log box on this page. There’s a full walkthrough for overnight drain on macOS 27.
Should I quit powerd or WindowServer if they appear?
No. powerd is the part of macOS that manages sleep. WindowServer draws the screen; quitting it logs you out. If they’re the only names in the list and nothing else is holding sleep, look at your settings instead.
Does this tool upload what I paste?
No. It runs in your browser. The output you paste never leaves your Mac, and we don’t store it.
Doing this with Brello
Brello is a Mac app we make. Its Health page shows what’s keeping your Mac awake in plain words. Brello is $19.99 for a limited time, then $29.99, one time, on up to 3 Macs, and runs on any Mac with macOS 14 or later. Refunds are within 30 days, no reason needed.
It reads only what’s on your Mac; nothing about your Mac leaves it, except for your license and updates. See pricing, or read how Brello keeps your Mac private.
Checked on macOS 27, December 4, 2026. This tool runs in your browser: nothing you type or paste is sent to us or stored.
Sources: pmset(1), the manual page; Set sleep and wake settings for your Mac (Apple Support); If your Mac sleeps or wakes unexpectedly (Apple Support).