cheat sheet
powercfg
Manage Windows power plans, enable or disable hibernation, diagnose battery health and sleep failures, and generate energy efficiency reports from the command prompt.
powercfg — Power Configuration CLI
What it is
powercfg is a built-in Windows command that controls the Power Management subsystem: it lets you list, create, activate, and delete power plans; enable or disable hibernation and fast startup; query sleep and wake source history; and generate detailed energy efficiency and battery reports. Use it in deployment scripts to enforce a power policy, in troubleshooting to diagnose why a machine won't sleep or wakes unexpectedly, and in battery health monitoring for laptops. Requires Administrator privileges for most operations.
Availability
powercfg ships as C:\Windows\System32\powercfg.exe on Windows XP and later. Most diagnostic switches require Windows 7+.
powercfg /?
Output:
POWERCFG /OPTION [ARGUMENTS] [/?]
Description:
Enables users to control the power settings on a local system.
...
Syntax
powercfg /option [arguments]
Output: (varies by option)
Essential options
| Switch | Meaning |
|---|---|
/list or /l | List all power plans (GUIDs and names) |
/getactivescheme | Show the currently active power plan |
/setactive <GUID> | Activate a power plan by GUID |
/duplicatescheme <GUID> | Duplicate a plan (creates a copy to customise) |
/deletescheme <GUID> | Delete a custom power plan |
/query [<GUID>] | Show all settings for a plan |
/change <setting> <value> | Change a single setting in the active plan |
| `/h on | off` |
/energy | Generate an energy efficiency HTML report |
/batteryreport | Generate an HTML battery health report |
/sleepstudy | Generate an HTML sleep diagnostic report |
/lastwake | Show the last wake source |
/waketimers | List active wake timers |
/requests | Show what is preventing sleep (process, service, driver) |
/requestsoverride | Override a sleep request |
/devicequery wake_armed | List devices allowed to wake the machine |
/deviceenablewake <device> | Allow a device to wake the system |
/devicedisablewake <device> | Prevent a device from waking the system |
/export <file> <GUID> | Export a power plan to a .pow file |
/import <file> | Import a power plan from a .pow file |
Listing and activating power plans
Three built-in power plans are available by well-known GUID. Custom plans created via the GUI get dynamically assigned GUIDs.
powercfg /list
Output:
Existing Power Schemes (* Active)
-----------------------------------
Power Scheme GUID: 381b4222-f694-41f0-9685-ff5bb260df2e (Balanced) *
Power Scheme GUID: 8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c (High performance)
Power Scheme GUID: a1841308-3541-4fab-bc81-f71556f20b4a (Power saver)
powercfg /getactivescheme
Output:
Power Scheme GUID: 381b4222-f694-41f0-9685-ff5bb260df2e (Balanced)
rem Activate High Performance plan
powercfg /setactive 8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c
Output:
(none — exits 0 on success)
Changing individual power settings
/change modifies a setting in the currently active plan. Common setting names: monitor-timeout-ac, monitor-timeout-dc, disk-timeout-ac, disk-timeout-dc, standby-timeout-ac, standby-timeout-dc, hibernate-timeout-ac, hibernate-timeout-dc. Values are in minutes; 0 = never.
rem Disable screen timeout on AC power
powercfg /change monitor-timeout-ac 0
Output:
(none — exits 0 on success)
rem Set sleep after 30 minutes on battery
powercfg /change standby-timeout-dc 30
Output:
(none — exits 0 on success)
Enabling and disabling hibernation
Hibernation saves RAM contents to hiberfil.sys and powers off the machine. Disabling it reclaims disk space equal to installed RAM and also disables Fast Startup.
rem Disable hibernation (removes hiberfil.sys)
powercfg /h off
Output:
(none — exits 0 on success)
rem Re-enable hibernation
powercfg /h on
Output:
(none — exits 0 on success)
Energy efficiency report (/energy)
/energy runs a 60-second trace of system activity and produces an HTML report listing inefficiencies, errors, and warnings that affect power consumption. The report path is printed at the end.
powercfg /energy
Output:
Enabling tracing for 60 seconds...
Observing system behavior...
Analyzing trace data...
Analysis complete.
Energy efficiency problems were found.
5 Errors
7 Warnings
21 Informational
See C:\Windows\system32\energy-report.html for details.
Battery report (/batteryreport)
/batteryreport generates a detailed HTML report of battery capacity history, charge cycles, and usage patterns — essential for diagnosing degraded laptop batteries.
powercfg /batteryreport /output C:\Reports\battery.html
Output:
Battery life report saved to file path C:\Reports\battery.html.
Sleep study (/sleepstudy)
/sleepstudy produces an HTML report of the machine's sleep session history — how long it slept, power consumed, and what caused it to wake. Available on systems with Modern Standby (S0 Low Power Idle).
powercfg /sleepstudy /output C:\Reports\sleepstudy.html
Output:
Sleep Study report saved to file path C:\Reports\sleepstudy.html.
Diagnosing sleep prevention (/requests and /lastwake)
/requests lists programs, drivers, and services that have posted a power request preventing the system from sleeping. /lastwake shows what triggered the most recent wake.
powercfg /requests
Output:
DISPLAY:
[PROCESS] \Device\HarddiskVolume3\Program Files\MyApp\myapp.exe
Preventing display from sleeping.
SYSTEM:
None.
AWAYMODE:
None.
powercfg /lastwake
Output:
Wake History Count - 1
Wake History [0]
Wake Source Count - 1
Wake Source [0]
Type: Wake Timer
Owner: [PROCESS] \Device\HarddiskVolume3\Windows\System32\svchost.exe
Owner Supplied Reason: Windows Update
Common pitfalls
- Most operations require elevation — run cmd.exe as Administrator; unprivileged calls return "Access is denied".
/h offalso disables Fast Startup — disabling hibernation prevents Fast Startup (hybrid shutdown); if boot time increases afterpowercfg /h off, this is why./energyrequires 60 seconds — the trace window cannot be shortened; budget time accordingly in scripts.- GUIDs vary across machines for custom plans — always use
powercfg /listto retrieve the GUID dynamically rather than hardcoding it in scripts. /changeaffects only the currently active plan — switch to the target plan first with/setactivebefore calling/change./batteryreportis only useful on battery-powered devices — on desktops it produces a report showing "N/A" for most battery fields.
Real-world recipes
Enforce High Performance plan in a deployment script
@echo off
rem Activate High Performance power plan
powercfg /setactive 8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c
rem Disable all sleep and hibernate timeouts on AC
powercfg /change standby-timeout-ac 0
powercfg /change hibernate-timeout-ac 0
powercfg /h off
echo Power plan configured for server use.
Output:
Power plan configured for server use.
Collect battery health report for a fleet of laptops
powercfg /batteryreport /output "\\fileserver\reports\battery_%COMPUTERNAME%.html"
echo Battery report saved for %COMPUTERNAME%.
Output:
Battery life report saved to file path \\fileserver\reports\battery_MYHOST.html.
Battery report saved for MYHOST.
Find what is preventing sleep
powercfg /requests
powercfg /waketimers
powercfg /lastwake
Output:
DISPLAY:
[PROCESS] \Device\...\myapp.exe
Preventing display from sleeping.
Timer Set By: [PROCESS] \Device\...\svchost.exe
Reason: Windows Update
Wake History [0]
Wake Source [0]
Type: Wake Timer
Owner Supplied Reason: Windows Update
Power plans and the well-known GUIDs
Windows ships with three predefined power plans. Their GUIDs are stable across every Windows release — you can hardcode them in deployment scripts. OEMs and group policy may also define hidden plans (Ultimate Performance, Recommended balanced settings); those plans appear in powercfg /list only after they're surfaced with powercfg -duplicatescheme.
| Plan | GUID | When to pick |
|---|---|---|
| Balanced | 381b4222-f694-41f0-9685-ff5bb260df2e | Default for laptops and most desktops |
| High performance | 8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c | Servers, gaming, latency-sensitive workloads |
| Power saver | a1841308-3541-4fab-bc81-f71556f20b4a | Battery-only, max runtime |
| Ultimate Performance | e9a42b02-d5df-448d-aa00-03f14749eb61 | Workstations/servers; hidden by default |
rem Surface the hidden Ultimate Performance plan
powercfg -duplicatescheme e9a42b02-d5df-448d-aa00-03f14749eb61
Output:
Power Scheme GUID: <new-guid> (Ultimate Performance)
Setting subgroups and individual settings (/setacvalueindex, /setdcvalueindex)
/change covers the common timeouts. For every other setting, powercfg exposes a two-level GUID hierarchy: subgroup (e.g. Hard disk, Sleep, Display) and setting (e.g. Turn off hard disk after, Hibernate after). Setting values uses setacvalueindex (plugged-in / AC) or setdcvalueindex (battery / DC).
rem List the active plan's subgroups and settings
powercfg /query
Output: (long block — sample)
Power Scheme GUID: 381b4222-f694-41f0-9685-ff5bb260df2e (Balanced)
Subgroup GUID: 0012ee47-9041-4b5d-9b77-535fba8b1442 (Hard disk)
Power Setting GUID: 6738e2c4-e8a5-4a42-b16a-e040e769756e (Turn off hard disk after)
Possible Setting Index: 000
Possible Setting Friendly Name: Never
...
Current AC Power Setting Index: 0x00000000
Current DC Power Setting Index: 0x00000258
rem Aliases — powercfg accepts well-known aliases instead of GUIDs
powercfg /aliases | findstr /I "hibernate sleep monitor"
Output:
GUID Alias
381b4222-f694-41f0-9685-ff5bb260df2e SCHEME_BALANCED
8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c SCHEME_MIN
a1841308-3541-4fab-bc81-f71556f20b4a SCHEME_MAX
238c9fa8-0aad-41ed-83f4-97be242c8f20 SUB_SLEEP
29f6c1db-86da-48c5-9fdb-f2b67b1f44da STANDBYIDLE
9d7815a6-7ee4-497e-8888-515a05f02364 HIBERNATEIDLE
7516b95f-f776-4464-8c53-06167f40cc99 SUB_VIDEO
3c0bc021-c8a8-4e07-a973-6b14cbcb2b7e VIDEOIDLE
rem Set max processor state to 80% on AC (limit CPU turbo)
powercfg /setacvalueindex SCHEME_CURRENT SUB_PROCESSOR PROCTHROTTLEMAX 80
powercfg /setactive SCHEME_CURRENT
Output: (none — exits 0 on success)
rem Set sleep after 5 minutes on battery for the active plan
powercfg /setdcvalueindex SCHEME_CURRENT SUB_SLEEP STANDBYIDLE 300
powercfg /setactive SCHEME_CURRENT
Output: (none — exits 0 on success)
rem Disable USB selective suspend (often the cause of "USB device not recognized" after sleep)
powercfg /setacvalueindex SCHEME_CURRENT 2a737441-1930-4402-8d77-b2bebba308a3 48e6b7a6-50f5-4782-a5d4-53bb8f07e226 0
powercfg /setactive SCHEME_CURRENT
Output: (none — exits 0 on success)
Always re-apply with
/setactive SCHEME_CURRENTafter/setacvalueindexor/setdcvalueindex— the new index value isn't picked up by the kernel until the active plan is re-activated.
Sleep states (/availablesleepstates)
powercfg /a reports which sleep states the firmware and OS support. The available states have changed dramatically over time — older platforms support classic S1/S3/S4; modern laptops use Modern Standby (S0 Low Power Idle). If a machine "won't sleep" because no sleep state is available, this is the diagnostic. Starting with Windows 11 24H2 (and confirmed by Microsoft in February 2026), Modern Standby includes a battery-drain protection: when excessive drain is detected, most wake sources are automatically disabled and the device can only be woken by the power button or lid open.
powercfg /a
Output:
The following sleep states are available on this system:
Standby (S0 Low Power Idle) Network Connected
Hibernate
Fast Startup
The following sleep states are not available on this system:
Standby (S1)
The system firmware does not support this standby state.
Standby (S2)
The system firmware does not support this standby state.
Standby (S3)
The system firmware does not support this standby state.
Hybrid Sleep
Hibernation is not available.
| State | Power draw | Resume time | Notes |
|---|---|---|---|
| S0 Low Power Idle | ~few W | instant | Modern Standby, fully network-aware |
| S1 | medium | <1s | CPU stopped, RAM refreshed — legacy |
| S3 | low | ~1-2s | Suspend to RAM — most laptops 2015+ |
| S4 / Hibernate | none | 10-30s | RAM written to hiberfil.sys |
| Hybrid Sleep | low | <2s | S3 + S4 combined; desktop default |
| Fast Startup | (boot) | <10s | Kernel hibernates on shutdown |
Battery report (/batteryreport) deep dive
powercfg /batteryreport produces an HTML report rich enough to plot battery degradation over time. The same data is also available as XML with /xml. Key sections:
| Section | What it tells you |
|---|---|
| Installed batteries | Manufacturer, design capacity, full charge capacity |
| Recent usage | Last 3 days of state changes (charging, discharging, idle) |
| Battery usage | Time-series of charge level over the last 3 days |
| Usage history | Daily aggregate active/connected-standby duration |
| Battery capacity history | Design vs full-charge capacity over time — wear curve |
| Battery life estimates | Estimated runtime at design vs current capacity |
rem Standard HTML report
powercfg /batteryreport /output C:\Reports\battery.html
Output:
Battery life report saved to C:\Reports\battery.html.
rem XML for downstream parsing
powercfg /batteryreport /output C:\Reports\battery.xml /xml
Output:
Battery life report saved to C:\Reports\battery.xml.
rem Two reports a week apart — compare wear
powercfg /batteryreport /output C:\Reports\battery_baseline.html
schtasks /create /tn "BatteryReportWeekly" /sc weekly /d Sun /st 09:00 ^
/tr "powercfg /batteryreport /output C:\Reports\battery_%%DATE:~-10,2%%-%%DATE:~-7,2%%-%%DATE:~-4,4%%.html"
Output:
Battery life report saved to C:\Reports\battery_baseline.html.
SUCCESS: The scheduled task "BatteryReportWeekly" has successfully been created.
# Calculate battery wear from the XML report
[xml]$br = Get-Content C:\Reports\battery.xml
$design = [int]$br.BatteryReport.Batteries.Battery.DesignCapacity
$full = [int]$br.BatteryReport.Batteries.Battery.FullChargeCapacity
$wear = [math]::Round((1 - ($full / $design)) * 100, 1)
"Design : $design mWh"
"Full : $full mWh"
"Wear : $wear %"
Output:
Design : 56000 mWh
Full : 49200 mWh
Wear : 12.1 %
Energy efficiency report (/energy) deep dive
/energy runs a 60-second ETW trace and produces an HTML report categorizing findings into Errors, Warnings, and Information. Common findings worth checking:
| Finding category | Example |
|---|---|
| Power policy | Display idle timeout high on AC |
| Platform timer resolution | Process X has raised the timer resolution (drains battery) |
| Processor utilization | Process Y > 5% over the 60-second sample |
| Devices | USB device blocking selective suspend |
| CPU utilization | Average CPU % is X over the trace |
rem Standard run — 60 seconds
powercfg /energy /output C:\Reports\energy.html
Output:
Enabling tracing for 60 seconds...
Observing system behavior...
Analyzing trace data...
Analysis complete.
Energy efficiency problems were found.
3 Errors
12 Warnings
17 Informational
See C:\Reports\energy.html for more details.
rem Longer trace (5 minutes) for intermittent issues
powercfg /energy /output C:\Reports\energy.html /duration 300
Output:
Enabling tracing for 300 seconds...
Observing system behavior...
Analyzing trace data...
Analysis complete.
See C:\Reports\energy.html for more details.
rem XML for parsing
powercfg /energy /output C:\Reports\energy.xml /xml
Output:
Enabling tracing for 60 seconds...
Observing system behavior...
Analyzing trace data...
Analysis complete.
See C:\Reports\energy.xml for more details.
rem Look at just the errors
powercfg /energy /output C:\Reports\energy.html
powershell -NoProfile -Command "Select-String -Path C:\Reports\energy.html -Pattern '<td class=\"errorname\"\">'"
Output:
Energy efficiency problems were found.
C:\Reports\energy.html:482: <td class="errorname">USB Suspend:USB Device not Entering Suspend</td>
C:\Reports\energy.html:511: <td class="errorname">Platform Timer Resolution:Outstanding Timer Request</td>
Sleep study (/sleepstudy)
/sleepstudy aggregates Modern Standby session data: how long each S0 session lasted, what fraction was in Active, Drips (low-power), or Resiliency (recovery from a faulty driver), and what drained the battery. Available on Modern Standby machines only — desktops will fail with Sleep Study requires Connected Standby support.
rem Standard report (last 3 days)
powercfg /sleepstudy /output C:\Reports\sleepstudy.html
Output:
Sleep Study report saved to C:\Reports\sleepstudy.html.
rem Custom window (last 28 days)
powercfg /sleepstudy /output C:\Reports\sleep28.html /duration 28
Output:
Sleep Study report saved to C:\Reports\sleep28.html.
rem Drill down on a specific battery drain offender from the report
powercfg /srumutil /output C:\Reports\srum.csv /csv
Output: (CSV of SRUM — System Resource Usage Monitor — energy attribution rows)
System Power Report (/systempowerreport)
/systempowerreport (alias /spr) generates an HTML report combining sleep diagnostics for Modern Standby and non-Modern-Standby systems. It's the successor to /sleepstudy on Windows 10/11 desktops.
powercfg /systempowerreport /output C:\Reports\sysenergy.html
Output:
System Power Report saved to C:\Reports\sysenergy.html.
Devices that wake the system
/devicequery is the inventory command for device wake-arming. Wake-on-LAN, mice/keyboards waking from sleep, and unexpected wake events all flow through this list.
rem Devices currently allowed to wake the machine
powercfg /devicequery wake_armed
Output:
HID Keyboard Device
HID-compliant mouse
Realtek PCIe GbE Family Controller
rem Devices that support wake
powercfg /devicequery wake_from_S3
Output:
HID Keyboard Device
HID-compliant mouse
Realtek PCIe GbE Family Controller
Intel(R) Wireless-AC 9560 160MHz
rem Allow / disallow wake for one device (exact name from /devicequery)
powercfg /deviceenablewake "HID Keyboard Device"
powercfg /devicedisablewake "Realtek PCIe GbE Family Controller"
Output: (none — exits 0 on success)
rem Find the device that woke the machine last
powercfg /lastwake
Output:
Wake History Count - 1
Wake History [0]
Wake Source Count - 1
Wake Source [0]
Type: Device
Instance Path: HID\VID_046D&PID_C52B&...
Friendly Name: HID Keyboard Device
Description: HID Keyboard Device
Manufacturer: (Standard keyboards)
Wake timers
Wake timers are scheduled tasks or applications that ask the kernel to wake the machine. They're a common cause of "the laptop turned itself on overnight". /waketimers lists active timers; the Allow wake timers power-setting controls whether they fire at all.
powercfg /waketimers
Output:
Timer set by [PROCESS] \Device\HarddiskVolume3\Windows\System32\svchost.exe (SystemEventsBroker) expires at 5/25/2026 03:00:00.
Reason: Windows will execute 'NT TASK\Microsoft\Windows\UpdateOrchestrator\Reboot' scheduled task that requested waking the computer.
rem Disable wake timers entirely on battery
powercfg /setdcvalueindex SCHEME_CURRENT SUB_SLEEP RTCWAKE 0
powercfg /setactive SCHEME_CURRENT
Output: (none — exits 0 on success)
/requests — what's preventing sleep right now
/requests lists every outstanding power request from a process, driver, or service. The classic culprits are media players (DISPLAY request), background sync apps, and printer drivers.
powercfg /requests
Output:
DISPLAY:
[PROCESS] \Device\HarddiskVolume3\Program Files\MyApp\myapp.exe
Preventing display from sleeping.
SYSTEM:
[DRIVER] \FileSystem\srvnet
An active remote client has recently sent requests to this machine.
AWAYMODE:
None.
EXECUTION:
None.
PERFBOOST:
None.
ACTIVELOCKSCREEN:
None.
rem Override a request from a misbehaving process — clears it once
powercfg /requestsoverride PROCESS myapp.exe DISPLAY
Output: (none — exits 0 on success)
rem List active overrides
powercfg /requestsoverride
Output:
PROCESS
------
myapp.exe DISPLAY
rem Remove an override
powercfg /requestsoverride PROCESS myapp.exe
Output: (none — exits 0 on success)
Exporting and importing power plans
Plans are stored in the registry but /export and /import use a portable .pow binary format that round-trips between machines. Use this to push a hardened power configuration to a fleet without group policy.
rem Export the active plan
for /f "tokens=4" %%g in ('powercfg /getactivescheme') do set ACTIVE=%%g
powercfg /export C:\Config\active.pow %ACTIVE%
Output: (none — exits 0 on success)
rem Import on the target — gets a new GUID
powercfg /import C:\Config\active.pow
powercfg /list
Output:
Existing Power Schemes (* Active)
-----------------------------------
Power Scheme GUID: 381b4222-f694-41f0-9685-ff5bb260df2e (Balanced) *
Power Scheme GUID: <new-guid> (Balanced)
rem Activate the imported plan by GUID
powercfg /setactive <new-guid>
Output: (none — exits 0 on success)
PowerShell equivalents
Get-PowerScheme and friends from the PowerManagement module wrap powercfg, returning structured objects.
# List plans (PowerShell objects, not text)
Get-CimInstance -Namespace root\cimv2\power -ClassName Win32_PowerPlan |
Select-Object ElementName, InstanceID, IsActive
Output:
ElementName InstanceID IsActive
----------- ---------- --------
Balanced Microsoft:PowerPlan\{381b4222-f694-41f0-9685-ff5bb260df2e} True
High performance Microsoft:PowerPlan\{8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c} False
Power saver Microsoft:PowerPlan\{a1841308-3541-4fab-bc81-f71556f20b4a} False
# Switch via WMI
$hp = Get-CimInstance -Namespace root\cimv2\power -ClassName Win32_PowerPlan |
Where-Object ElementName -eq 'High performance'
Invoke-CimMethod -InputObject $hp -MethodName Activate
# Current battery level
(Get-CimInstance -Namespace root\WMI -ClassName BatteryStatus -ErrorAction SilentlyContinue).RemainingCapacity
# Battery design vs full capacity via WMI (alternative to /batteryreport)
$design = (Get-CimInstance -Namespace root\WMI -ClassName BatteryStaticData).DesignedCapacity
$full = (Get-CimInstance -Namespace root\WMI -ClassName BatteryFullChargedCapacity).FullChargedCapacity
'Wear: {0:N1}%' -f ((1 - $full/$design) * 100)
Output: Wear: 12.1%
# Watching wake events via the kernel-power channel
Get-WinEvent -FilterHashtable @{
LogName = 'System'
ProviderName = 'Microsoft-Windows-Kernel-Power'
Id = 107, 42, 1
} -MaxEvents 20 |
Select-Object TimeCreated, Id,
@{ N='Action'; E={
switch ($_.Id) {
1 { 'Sleep' }
42 { 'Sleep' }
107 { 'Resume' }
}
}}
Output:
TimeCreated Id Action
----------- -- ------
5/25/2026 06:30:00 107 Resume
5/25/2026 02:14:11 42 Sleep
5/24/2026 23:14:00 107 Resume
5/24/2026 18:00:00 42 Sleep
Common pitfalls
- Most operations require elevation — run cmd.exe as Administrator; unprivileged calls return "Access is denied".
/h offalso disables Fast Startup — disabling hibernation prevents Fast Startup (hybrid shutdown); if boot time increases afterpowercfg /h off, this is why./energyrequires 60 seconds — the trace window cannot be shortened; budget time accordingly in scripts.- GUIDs vary across machines for custom plans — always use
powercfg /listto retrieve the GUID dynamically rather than hardcoding it in scripts. /changeaffects only the currently active plan — switch to the target plan first with/setactivebefore calling/change./batteryreportis only useful on battery-powered devices — on desktops it produces a report showing "N/A" for most battery fields.setacvalueindex/setdcvalueindexdon't take effect until/setactive— silent gotcha; new value is staged but not activated./sleepstudyrequires Modern Standby — on desktops or older laptops use/systempowerreportinstead.- Wake timer scheduled tasks override the power policy — even with "Allow wake timers" disabled, a task with
RunOnlyIfNetworkAvailable=falseandWakeToRun=truecan still wake the system. Audit withschtasks /query /v /fo csv | findstr "Wake To Run". /requestsshows zero while the user is at the console — request enumeration filters out interactive-session DISPLAY requests by default. Run withpsexec -s -i powercfg /requestsfrom a SYSTEM context to see them all.- Group Policy can override
/setactive— domain-deployed plans (Computer Configuration → Policies → Administrative Templates → System → Power Management) override the local active scheme on each policy refresh. Audit withgpresult /h C:\gp.html. hiberfil.syscan balloon to 75% of RAM — Windows allocates the file at hibernation file size =HiberFileSizePercentof RAM (default 75%). Shrink withpowercfg /h /type reducedif disk-constrained.
Real-world recipes
Enforce High Performance plan in a deployment script
@echo off
rem Activate High Performance power plan
powercfg /setactive 8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c
rem Disable all sleep and hibernate timeouts on AC
powercfg /change standby-timeout-ac 0
powercfg /change hibernate-timeout-ac 0
powercfg /h off
echo Power plan configured for server use.
Output:
Power plan configured for server use.
Collect battery health report for a fleet of laptops
powercfg /batteryreport /output "\\fileserver\reports\battery_%COMPUTERNAME%.html"
echo Battery report saved for %COMPUTERNAME%.
Output:
Battery life report saved to file path \\fileserver\reports\battery_MYHOST.html.
Battery report saved for MYHOST.
Find what is preventing sleep
powercfg /requests
powercfg /waketimers
powercfg /lastwake
Output:
DISPLAY:
[PROCESS] \Device\...\myapp.exe
Preventing display from sleeping.
Timer Set By: [PROCESS] \Device\...\svchost.exe
Reason: Windows Update
Wake History [0]
Wake Source [0]
Type: Wake Timer
Owner Supplied Reason: Windows Update
Audit battery wear across a laptop fleet
$hosts = Get-Content C:\Audit\laptops.txt
$report = foreach ($h in $hosts) {
Invoke-Command -ComputerName $h -ScriptBlock {
$xml = "$env:TEMP\battery_$env:COMPUTERNAME.xml"
powercfg /batteryreport /output $xml /xml | Out-Null
[xml]$br = Get-Content $xml
$bat = $br.BatteryReport.Batteries.Battery
if ($bat) {
[PSCustomObject]@{
Host = $env:COMPUTERNAME
Serial = $bat.SerialNumber
Design = [int]$bat.DesignCapacity
Full = [int]$bat.FullChargeCapacity
WearPct = [math]::Round((1 - ([int]$bat.FullChargeCapacity)/([int]$bat.DesignCapacity))*100,1)
}
}
}
}
$report | Sort-Object WearPct -Descending | Format-Table -AutoSize
Output:
Host Serial Design Full WearPct
---- ------ ------ ---- -------
LAP-12 ABC123 56000 38400 31.4
LAP-08 DEF456 56000 49200 12.1
LAP-15 GHI789 56000 54800 2.1
"Lid closed, no sleep" diagnostic
When closing the lid no longer suspends the machine, walk through this sequence.
rem 1. Verify sleep is available
powercfg /a
rem 2. Confirm the lid-close action
powercfg /q SCHEME_CURRENT SUB_BUTTONS LIDACTION
rem 3. Show outstanding sleep requests
powercfg /requests
rem 4. Run a 60s energy trace
powercfg /energy /output %TEMP%\energy.html
Output: (combined — each step prints its own report; see individual command outputs above)
Battery-saver script for kiosk machines
A kiosk wakes from sleep only on power-button press, never on network or RTC.
@echo off
powercfg /setactive SCHEME_BALANCED
rem Lid action: do nothing
powercfg /setacvalueindex SCHEME_CURRENT SUB_BUTTONS LIDACTION 0
powercfg /setdcvalueindex SCHEME_CURRENT SUB_BUTTONS LIDACTION 0
rem Disable wake timers
powercfg /setacvalueindex SCHEME_CURRENT SUB_SLEEP RTCWAKE 0
powercfg /setdcvalueindex SCHEME_CURRENT SUB_SLEEP RTCWAKE 0
rem Disable WoL
for /f "tokens=*" %%d in ('powercfg /devicequery wake_armed') do (
powercfg /devicedisablewake "%%d"
)
powercfg /setactive SCHEME_CURRENT
echo Kiosk power policy applied.
Output:
Kiosk power policy applied.
Pre-deploy a custom plan via .pow
rem On the gold image
powercfg /export C:\Config\gold.pow SCHEME_CURRENT
rem On each target via PowerShell remoting
Invoke-Command -ComputerName (gc hosts.txt) -ScriptBlock {
Copy-Item \\fileserver\config\gold.pow C:\Temp\gold.pow
$out = powercfg /import C:\Temp\gold.pow
$guid = ($out -split '\s')[3]
powercfg /setactive $guid
}
Output: (none — exits 0 on success on each host)
Calculate uptime spent in each power state
The SRUM database has this; powercfg /srumutil dumps it as CSV.
powercfg /srumutil /output %TEMP%\srum.csv /csv
powershell -NoProfile -Command "Import-Csv $env:TEMP\srum.csv | Group-Object PowerState | Sort-Object Count -Descending | Format-Table Count,Name -AutoSize"
Output:
Count Name
----- ----
8124 Active
1432 ConnectedStandby
42 Sleep
12 Hibernate
Catch a runaway "preventing sleep" process
When a process consistently shows up in /requests blocking sleep, append a daily snapshot to a log so you can correlate with user complaints.
$log = "C:\Logs\sleep-requests_$(Get-Date -Format yyyy-MM).log"
"--- $(Get-Date -Format s) ---" | Add-Content $log
powercfg /requests | Add-Content $log
Reduce hiberfil.sys when disk is tight
The reduced hibernation file is half the size of full and only supports Fast Startup, not real hibernation.
rem Trim hiberfil.sys to ~40% of RAM
powercfg /h /type reduced
powercfg /h /size 50
dir C:\hiberfil.sys
Output:
05/25/2026 10:14 8,589,934,592 hiberfil.sys
Related tools
logman— the underlying ETW machinerypowercfg /energyuses.schtasks— investigate wake timers andWakeToRun=truetasks.wevtutil— Kernel-Power events (sleep/resume/unexpected reboot).sc— thePowerservice that hosts all ofpowercfg.systeminfo— pair withpowercfg /afor a complete platform snapshot.driverquery— drivers blocking selective suspend show up here.bcdedit— hypervisorlaunchtype and other boot flags interact with hibernation.
Sources
- Microsoft confirms Windows 11 no longer triggers unexpected wake-ups due to Modern Standby — Windows Latest, Feb 2026
- Windows 11 24H2 Modern Standby Limits Wake Sources to Save Battery Life — Windows Forum
- Microsoft quietly improved Windows 11 25H2, 24H2 Modern Standby — Neowin
- How to Change Power and Sleep Settings in Windows 11 — 2026 Guide