Powercfg Command-Line Options
Powercfg.exe is used to control power plans (power schemes), manage device power states, and analyze system energy efficiency and battery life issues.
Syntax
- powercfg /option [arguments] [/?]
- option: One of the options from the predefined list
- arguments: Optional arguments applicable to the selected option
Key Options and Their Descriptions
- /?, -help: Displays command-line parameter information.
- /list, /L: Lists all power schemes.
- /query, /Q: Shows the contents of a power scheme.
- /change, /X: Modifies a setting in the current power scheme.
- /changename: Changes the name and description of a power scheme.
- /duplicatescheme: Duplicates a power scheme.
- /delete, /D: Deletes a specified power scheme.
- /deletesetting: Deletes a power setting.
- /setactive, /S: Activates a specified power scheme.
- /getactivescheme: Retrieves the active power scheme.
- /setacvalueindex: Sets a power setting value when powered by AC.
- /setdcvalueindex: Sets a power setting value when powered by DC.
- /import: Imports power settings from a file.
- /export: Exports a power scheme to a file.
- /aliases: Displays all aliases and corresponding GUIDs.
- /getsecuritydescriptor: Gets security descriptor of power settings/schemes.
- /setsecuritydescriptor: Sets security descriptor of power settings/schemes.
- /hibernate, /H: Enables or disables hibernation.
- /availablesleepstates, /A: Reports available sleep states.
- /devicequery: Lists devices based on criteria (e.g., wake capability).
- /deviceenableawake: Enables a device to wake the system.
- /devicedisablewake: Disables a device from waking the system.
- /lastwake: Reports what woke the system from last sleep.
- /waketimers: Enumerates active wake timers.
- /requests: Enumerates Power Requests from applications/drivers.
- /requestsoverride: Sets Power Request overrides.
- /energy: Analyzes system for energy efficiency issues.
- /batteryreport: Generates a battery usage report.
- /sleepstudy: Produces a sleep quality diagnostic report.
- /srumutil: Dumps Energy Estimation data.
- /systemsleepdiagnostics: Reports on system sleep transitions.
- /systempowerreport: Generates a report on power transitions.
Key Command Examples
/query or /Q
- Command:
powercfg /query [scheme_GUID] [sub_GUID]
- scheme_GUID: Identifier for power scheme.
- sub_GUID: Identifier for power-setting subgroup.
Examples:
powercfg /query
powercfg /query 381b4222-f694-41f0-9685-ff5bb260df2e 238c9fa8-0aad-41ed-83f4-97be242c8f20
/change or /X
- Command:
/change setting value
- setting: Type like monitor-timeout-ac
- value: New value in minutes
Example:
powercfg /change monitor-timeout-ac 5
Overlays and PPM Profiles
- Overlay schemes are limited to performance vs. power savings trade-off settings.
- Commands for overlays and PPM profiles:
powercfg /setacvalueindex overlay_scheme_alias subgroup_alias setting_alias value
powercfg /setdcvalueindex overlay_scheme_alias subgroup_alias setting_alias value
Generating XML for Provisioning
- Command:
powercfg /pxml /output output_file_path
- Can specify version, name, id, owner.
These commands and options provide comprehensive control over power settings and diagnostics on Windows systems.