pmset

Power management settings.

Syntax

   Settings for battery(-b), charger(-c), UPS(-u), All(-a):

      pmset [-a | -b | -c | -u] [setting value] [...]

   List current settings (Get):
   
      pmset -g [custom | live | cap | sched | ups | ps | ...full Getting list below]

   UPS settings:

      pmset -u [haltlevel percent] [haltafter minutes] [haltremain minutes]

   Override settings and sleep now:

      pmset [sleepnow | displaysleepnow | boot | noidle | lock | touch]

      pmset relative [wake | poweron] seconds

   Schedule:

      pmset schedule [cancel] [cancelall] {sleep | wake | poweron | shutdown | wakeorpoweron}
               "MM/dd/yy HH:mm:ss" [owner]

      pmset repeat cancel

      pmset repeat {sleep | wake | poweron | shutdown | wakeorpoweron}
               weekdays "MM/dd/yy HH:mm:ss"
               Where weekdays is a subset of MTWRFSU ("M" and "MTWRF" are valid strings)

Key:
SETTINGS
   acwake      - Wake the machine when power source (AC/battery) is changed (value = 0/1)

   autorestart - Automatic restart on power loss (value = 0/1)

   destroyfvkeyonstandby - Destroy File Vault Key when going to standby mode.
                   By default File vault keys are retained even when system goes to standby.
                   If the keys are destroyed, user will be prompted to enter the password
                   while coming out of standby mode.(value: 1 - Destroy, 0 - Retain)

   displaysleep - Display sleep timer; replaces 'dim' argument in 10.4
                 (value in minutes, or 0 to disable)

   disksleep  - Disk spindown timer; replaces 'spindown' argument in 10.4
                (value in minutes, or 0 to disable)

   lidwake    - Wake the machine when the laptop lid (or clamshell) is opened (value = 0/1)

   lessbright - Slightly turn down display brightness when switching to this
                power source (value = 0/1)

   halfdim    - Display sleep will use an intermediate half-brightness state
                between full brightness and fully off  (value = 0/1)

   hibernatemode - Change hibernation mode. (value =integer)
                   Please use caution not all hardware supports all modes. Check local man page.
                   0 = Normal sleep, no hibernation (default on desktops),
                   1 = Legacy Hibernate mode, RAM written to disk and system unpowered,
                   3 = Safe Sleep (default on laptops),
                   5 = the same as mode 1, but for use with secure virtual memory.
                   7 = the same as mode 3, but for use with secure virtual memory.
                  25 = Hibernate mode, only settable via pmset. The system will store a copy of
                       memory to persistent storage (the disk), and will remove power to memory.
                       The system will restore from disk image. If you want "hibernation" - slower sleeps,
                       slower wakes, and better battery life, use this setting. post-2005, MacOS 10.7+.

   hibernatefile - Change hibernation image file location. Image can  only be
                   located on the root volume. Please use caution. (value = path)

   networkoversleep - This setting affects how macOS networking presents shared
                      network services during system sleep. This setting is not
                      used by all platforms; changing its value is unsupported.

   powerbutton - Sleep the machine when power button is pressed, instead of shutting it down, (value=0/1)

   powernap   - Enable/disable Power Nap on supported machines (value = 0/1)

   proximitywake - On supported systems, this option controls system wake from sleep based
                   on proximity of devices using same iCloud id. (value = 0/1)

   reduce      - Permanently reduce processor speed (value = 0/1)

   ring       - Wake on modem ring (value = 0/1)

   sleep      - System sleep timer (value in minutes, or 0 to disable)

   sms        - Use Sudden Motion Sensor to park disk heads on sudden changes in G
                force (value = 0/1)

   ttyskeepawake - Prevent idle system sleep when any tty (e.g. remote login
                   session) is 'active'. A tty is 'inactive' only when its idle time exceeds
                   the system sleep timer. (value = 0/1)

   womp       - Wake on ethernet magic packet (value = 0/1)

GETTING
   -g          (with no argument) display the settings currently in use.

   -g live     Display the settings currently in use. (default if no argument given)

   -g everything   Print output from every argument under the GETTING header.
                   This is useful for quickly collecting all the output that pmset provides.

   -g ac / adapter Display details about an attached AC power adapter.
                   Only supported for MacBook and MacBook Pro.

   -g assertions  Display a summary of power assertions.
                  Assertions can  prevent system sleep or display sleep. 10.6+

   -g assertionslog Show a log of assertion creations and releases. 10.6+

   -g custom   Display custom settings for all power sources, although
               these settings might not currently be in use; a pre-set settings profile
               might be active instead.

   -g cap      Display which power management features the machine supports.

   -g history  A debugging tool. Prints a timeline of system sleeplwake UUIDs, when
               enabled with boot-arg io=0x3000000.

   -g historydetailed Print driver-level timings for a sleep/wake.
               Pass a UUID as an argument.

   -g log      Display a history of sleeps, wakes, and other power management events.
               This log is for admin & debugging purposes.

   -g powerstate [class names]
               Print the current power states for I/O Kit drivers. Caller may provide one or
               more I/O Kit class names (separated by spaces) as an argument.
               If no classes are provided, it will print all drivers' power states.

   -g powerstatelog [-i interval] [class names]
                  Periodically print the power state residency times for some drivers.
                  Caller may provide one or more I/O Kit class names (separated by spaces).
                  If no classes are provided, it will log the IOPower plane's root registry entry.
                  Caller may specify a polling interval, in seconds with -i polling_interval;
                  otherwise it defaults to 5 seconds.

   -g profiles    Display the settings associated with each Energy Saver profile. 10.5+

   -g ps /batt    Display status of batteries and UPSs.

   -g pslog       Display an ongoing log of power source (battery and UPS)state.

   -g rawlog      Display an ongoing log of battery state as read directly from battery.

   -g sched       Display scheduled startup/wake and shutdown/sleep events.

   -g stats       Print the counts for number sleeps and wakes system has gone thru since boot.

   -g systemstate Print the current power state of the system and available capabilites.

   -g sysload     Display the "system load advisory" - a summary of system activity
                  available from the IOGetSystemLoadAdvisory API. 10.6+

   -g sysloadlog  Display an ongoing log of lives changes to the system load advisory. 10.6+


   -g therm    Show thermal conditions that affect CPU speed. Not available on all platforms.

   -g thermlog    Show a log of thermal notifications that affect CPU speed.
                  Not available on all platforms.

   -g uuid        Display the currently active sleep/wake UUID; used within macOS to correlate
                  sleep/wake activity within one sleep cycle.

   -g uuidlog     Display the currently active sleep/wake UUID, and prints a new UUID as
                  they're set by the system.

   -g ups         Display UPS emergency thresholds.

pmset must be run as root in order to modify any settings.
See man pmset for a description of power management with more examples.

In system preferences âžž Energy saver you can set Sleep times and 'Wake for Network Access'

Hibernation and Safe Sleep modes will turn OFF RAM memory during sleep.

The macOS Energy Saver preference file is stored at:
/Library/Preferences/SystemConfiguration/com.apple.PowerManagement.plist
If energy saving preferences are not 'sticking', then trashing this preference file and rebooting will usually fix things.

Scheduled power on/off events are stored separately in /Library/Preferences/SystemConfiguration/com.apple.AutoWake.plist

Examples

Print the power management settings in use by the system:

$ pmset -g

Print a snapshot of battery/power source state at the moment:

$ pmset -g batt

Set displaysleep to a 5 minute timer on battery power, leaving other settings on battery power and other power sources
unchanged:

$ sudo pmset -b displaysleep 5

Restore default settings for charger, battery and UPS:

$ sudo pmset -c 2 -b 1 -u 1

Sets displaysleep to 10, disksleep to 10, system sleep to 30, and turns on WakeOnMagicPacket for ALL power sources (AC, Battery, and UPS) as appropriate:

$ sudo pmset -a displaysleep 10 disksleep 10 sleep 30 womp 1

Schedule the system to automatically wake from sleep on July 4, 2026, at 8PM:

$ sudo pmset schedule wake "07/04/16 20:00:00"

Set the hibernation mode to normal sleep:

$ sudo pmset -a hibernatemode 0

Restart the computer at midnight every day:

$ sudo pmset repeat restart MTWRFSU 00:00:00

Cancel all scheduled system sleep, shutdown, wake, and power on events:

$ sudo pmset repeat cancel

“Work like you don’t need the money, love like you've never been hurt, and dance like nobodys watching” ~ Satchel 'Satchmo' Paige

Related macOS commands

Local man page: pmset - Command line help page on your local machine.
caffeinate - Prevent the system from sleeping.
powermetrics - Gather and display CPU usage stats.


 
Copyright © 1999-2026 SS64.com
Some rights reserved