Share via


Powercfg Command-Line Options

Applies To: Windows 8, Windows 8.1, Windows Server 2012, Windows Server 2012 R2

You can use the powercfg.exe tool to control power schemes (also named power plans) to use the available sleep states, to control the power states of individual devices, and to analyze the system for common energy-efficiency and battery-life problems.

powercfg /COMMAND [ARGUMENTS] [/?]

Parameters

The following command-line options are available for powercfg.

Option Argument Description

-HELP, /?

Displays information about command-line parameters.

/LIST, /L

Lists all power schemes.

Examples:

POWERCFG /LIST

/QUERY, /Q

[<SCHEME_GUID> [<SUB_GUID>]]

Displays the contents of the specified power scheme. If neither the parameter SCHEME_GUID or SUB_GUID are provided, the settings of the current active power scheme are displayed. If the parameter SUB_GUID is not specified, all settings in the specified power scheme are displayed.

Arguments:

  • <SCHEME_GUID> Specifies a power scheme GUID. The POWERCFG /LIST command returns a power scheme GUID.

  • <SUB_GUID> Specifies a power-setting subgroup GUID. A power setting subgroup GUID is returned from the POWERCFG /QUERY command.

Examples:

POWERCFG /QUERY
POWERCFG /QUERY 381b4222-f694-41f0-9685-ff5bb260df2e 238c9fa8-0aad-41ed-83f4-97be242c8f20

/CHANGE, /x

<SETTING> <VALUE>

Modifies a setting value in the current power scheme.

Arguments:

  • <SETTING> Specifies one of the following options:
    monitor-timeout-ac
    monitor-timeout-dc
    disk-timeout-ac
    disk-timeout-dc
    standby-timeout-ac
    standby-timeout-dc
    hibernate-timeout-ac
    hibernate-timeout-dc

  • <VALUE> Specifies the new value, in minutes.

Examples:

POWERCFG /CHANGE monitor-timeout-ac 5

/CHANGENAME

<SCHEME_GUID> <NAME> [<DESCRIPTION>]

Modifies the name of a power scheme and optionally its description.

Arguments:

  • <SCHEME_GUID> Specifies a power scheme GUID. The POWERCFG /LIST command returns a power scheme GUID.

  • <NAME> Specifies the power scheme's new name.

  • <DESCRIPTION> Specifies the power scheme's new description. If no description is specified, only the name is changed.

Examples:

POWERCFG /CHANGENAME 381b4222-f694-41f0-9685-ff5bb260df2e "Customized Balanced"

/DUPLICATESCHEME

<SCHEME_GUID> [<DESTINATION_GUID>]

Duplicates the specified power scheme. The resulting GUID which represents the new scheme is displayed.

Arguments:

  • <SCHEME_GUID> Specifies a power scheme GUID. A power scheme GUID is returned from the POWERCFG /LIST command.

  • <DESTINATION_GUID> Specifies the new power scheme's GUID. If no GUID is specified, a new GUID is created.

Examples:

POWERCFG /DUPLICATESCHEME 381b4222-f694-41f0-9685-ff5bb260df2e

/DELETE, /D

<SCHEME_GUID>

Deletes the power scheme with the specified GUID.

Arguments:

  • <SCHEME_GUID> Specifies a power scheme GUID. A power scheme GUID is returned from the POWERCFG /LIST command.

Examples:

POWERCFG /DELETE 381b4222-f694-41f0-9685-ff5bb260df2e

/DELETESETTING

<SUB_GUID> <SETTING_GUID>

Deletes a power setting.

Arguments:

  • <SUB_GUID> Specifies a power setting subgroup GUID. A power setting subgroup GUID is returned from the POWERCFG /QUERY command.

  • <SETTING_GUID> Specifies a power setting GUID. A power setting GUID is returned from the POWERCFG /QUERY command.

Examples:

POWERCFG /DELETESETTING 238c9fa8-0aad-41ed-83f4-97be242c8f20 29f6c1db-86da-48c5-9fdb-f2b67b1f44da

/SETACTIVE, /S

<SCHEME_GUID>

Makes the specified power scheme active on the system.

Arguments:

  • <SCHEME_GUID> Specifies a power scheme GUID. A power scheme GUID is returned from the POWERCFG /LIST command.

Examples:

POWERCFG /SETACTIVE 381b4222-f694-41f0-9685-ff5bb260df2e

/GETACTIVESCHEME

Retrieves the currently active power scheme.

Examples:

POWERCFG /GETACTIVESCHEME

/SETACVALUEINDEX

<SCHEME_GUID> <SUB_GUID> <SETTING_GUID> <SETTING_INDEX>

Sets the value associated with a specified power setting while the system is powered by AC power.

Arguments:

  • <SCHEME_GUID> Specifies a power scheme GUID. A power scheme GUID is returned from the POWERCFG /LIST command.

  • <SUB_GUID> Specifies a power setting subgroup GUID. A power setting subgroup GUID is returned from the POWERCFG /QUERY command.

  • <SETTING_GUID> Specifies a power setting GUID. A power setting GUID is returned from the POWERCFG /QUERY command.

  • <SETTING_INDEX> Specifies which possible value this setting is set to. A list of possible values is returned from the POWERCFG /QUERY command.

Examples:

POWERCFG /SETACVALUEINDEX 381b4222-f694-41f0-9685-ff5bb260df2e 238c9fa8-0aad-41ed-83f4-97be242c8f20 29f6c1db-86da-48c5-9fdb-f2b67b1f44da 0

/SETDCVALUEINDEX

<SCHEME_GUID> <SUB_GUID> <SETTING_GUID> <SETTING_INDEX>

Sets the value associated with a specified power setting while the system is powered by DC power.

Arguments:

  • <SCHEME_GUID> Specifies a power scheme GUID. A power scheme GUID is returned from the POWERCFG /LIST command.

  • <SUB_GUID> Specifies a power setting subgroup GUID. A power setting subgroup GUID is returned from the POWERCFG /QUERY command.

  • <SETTING_GUID> Specifies a power setting GUID. A power setting GUID is returned from the POWERCFG /QUERY command.

  • <SETTING_INDEX> Specifies which possible value this setting is set to. A list of possible values is returned from the POWERCFG /QUERY command.

Examples:

POWERCFG /SETDCVALUEINDEX 381b4222-f694-41f0-9685-ff5bb260df2e 238c9fa8-0aad-41ed-83f4-97be242c8f20 29f6c1db-86da-48c5-9fdb-f2b67b1f44da 300

/IMPORT

<FILENAME> [<GUID>]

Imports a power scheme from the specified file.

Arguments:

  • <FILENAME> Specifies a fully-qualified path to a file generated by the POWERCFG /EXPORT command.

  • <GUID> Specifies the GUID for the imported scheme. If no GUID is specified, a new GUID is created.

Examples:

POWERCFG /IMPORT c:\scheme.pow

/EXPORT

<FILENAME> <GUID>

Exports a power scheme, represented by the specified GUID, to the specified file.

Arguments:

  • <FILENAME> Specifies a fully-qualified path to a destination file.

  • <GUID> Specifies a power scheme GUID. A power scheme GUID is returned from the POWERCFG /LIST command.

Examples:

POWERCFG /EXPORT c:\scheme.pow 381b4222-f694-41f0-9685-ff5bb260df2e

/ALIASES

Displays a list of aliases and their corresponding GUIDs. These aliases may be used instead of a GUID in any command.

Examples:

POWERCFG /ALIASES
Note
Some settings do not contain aliases. For a full list of GUIDs, use powercfg -q.

/GETSECURITYDESCRIPTOR

<GUID|ACTION>

Gets the security descriptor associated with the specified power setting, power scheme, or action.

Arguments:

  • <GUID> Specifies a power scheme or a power setting GUID. A power scheme GUID is returned from the POWERCFG /LIST command. A power setting GUID is returned from the POWERCFG /QUERY command.

  • <ACTION> Specifies one of the following actions: ActionSetActive, ActionCreate, ActionDefault.

Examples:

POWERCFG /GETSECURITYDESCRIPTOR 381b4222-f694-41f0-9685-ff5bb260df2e
POWERCFG /GETSECURITYDESCRIPTOR ActionSetActive

/SETSECURITYDESCRIPTOR

<GUID|ACTION> <SDDL>

Sets a security descriptor associated with the specified power setting, power scheme, or action.

Arguments:

  • <GUID> Specifies a power scheme or a power setting GUID. A power scheme GUID is returned from the POWERCFG /LIST command. A power setting GUID is returned from the POWERCFG /QUERY command.

  • <ACTION> Specifies one of the following actions: ActionSetActive, ActionCreate, ActionDefault.

  • <SDDL> Specifies a valid security descriptor string in SDDL format. An example SDDL string can be obtained from the POWERCFG /GETSECURITYDESCRIPTOR command.

Examples:

POWERCFG /SETSECURITYDESCRIPTOR 381b4222-f694-41f0-9685-ff5bb260df2e O:BAG:SYD:P(A;CI;KRKW;;;BU)(A;CI;KA;;;BA)(A;CI;KA;;;SY)(A;CI;KA;;;CO)
POWERCFG /SETSECURITYDESCRIPTOR ActionSetActive O:BAG:SYD:P(A;CI;KR;;;BU)(A;CI;KA;;;BA)(A;CI;KA;;;SY)(A;CI;KA;;;CO)

/HIBERNATE, /H

{ON | OFF | SIZE<PERCENT_SIZE>}

Enables or disables the hibernate feature or sets the hiberfile size.

Arguments:

  • ON Enables the hibernate feature.

  • OFF Disables the hibernate feature.

  • /SIZE<PERCENT_SIZE> Specifies the desired hiberfile size as a percentage of the total memory size. The default size cannot be smaller than 50. This parameter also causes hibernation to be enabled.

Examples:

POWERCFG /HIBERNATE OFF
POWERCFG /HIBERNATE /SIZE 100

/AVAILABLESLEEPSTATES, /A

Reports the sleep states available on the system. Attempts to report reasons why sleep states are unavailable.

Examples:

POWERCFG /AVAILABLESLEEPSTATES

/DEVICEQUERY

<QUERYFLAG>

Returns a list of devices that meet the specified criteria.

Arguments:

  • <QUERYFLAG> Specifies one of the following criteria:

    wake_from_S1_supported Returns all devices that support waking the system from a light sleep state.

    wake_from_S2_supported Returns all devices that support waking the system from a deeper sleep state.

    wake_from_S3_supported Returns all devices that support waking the system from the deepest sleep state.

    wake_from_any Returns all devices that support waking the system from any sleep state.

    S1_supported Lists devices supporting light sleep.

    S2_supported Lists devices supporting deeper sleep.

    S3_supported Lists devices supporting deepest sleep. S4_supported List devices supporting hibernation.

    wake_programmable Lists devices that are user-configurable to wake the system from a sleep state.

    wake_armed Lists devices that are currently configured to wake the system from any sleep state.

    all_devices Returns all devices present in the system.

Examples:

POWERCFG /DEVICEQUERY wake_armed

/DEVICEENABLEWAKE

<DEVICENAME>

Enables the specified device to wake the system from a sleep state.

Arguments:

  • <DEVICENAME> Specifies a device. This device name may be retrieved using POWERCFG /DEVICEQUERY wake_programmable.

Examples:

POWERCFG /DEVICEENABLEWAKE "Microsoft USB IntelliMouse Optical"

/DEVICEDISABLEWAKE

<DEVICENAME>

Disables the specified device from waking the system from a sleep state.

Arguments:

  • <DEVICENAME> Specifies a device. This device name may be retrieved using POWERCFG /DEVICEQUERY wake_armed.

Examples:

POWERCFG /DEVICEDISABLEWAKE "Microsoft USB IntelliMouse Optical"

/LASTWAKE

Reports information about what woke the system from the last sleep transition.

Examples:

POWERCFG /LASTWAKE

/WAKETIMERS

Enumerates the active wake timers. If enabled, the expiration of a wake timer wakes the system from sleep and hibernate states.

Examples:

POWERCFG /WAKETIMERS

/REQUESTS

Enumerates application and driver Power Requests. Power Requests prevent the computer from automatically powering off the display or entering a low-power sleep mode.

Examples:

POWERCFG /REQUESTS

/REQUESTSOVERRIDE

[<CALLER_TYPE> <NAME><REQUEST>]

Sets a Power Request override for a particular process, service, or driver. If no parameters are specified, this command displays the current list of Power Request overrides.

Arguments:

  • <CALLER_TYPE> Specifies one of the following caller types: PROCESS, SERVICE, DRIVER. This is obtained by calling the POWERCFG /REQUESTS command.

  • <NAME> Specifies the caller name. This is the name returned from calling the POWERCFG /REQUESTS command.

  • <REQUEST> Specifies one or more of the following Power Request types: DISPLAY, SYSTEM, AWAYMODE.

Examples:

POWERCFG /REQUESTSOVERRIDE PROCESS wmplayer.exe DISPLAY SYSTEM

/ENERGY

[/OUTPUT<FILENAME>] [/XML] [/DURATION<SECONDS>]

or

/TRACE [/D<FILEPATH>] [/XML] [/DURATION<SECONDS>]

Analyzes the system for common energy-efficiency and battery-life problems. The ENERGY command should be used when the computer is idle and has no open programs or documents. The ENERGY command generates an HTML report file in the current path.

Arguments:

  • /OUTPUT<FILENAME> Specify the path and file name to store the energy report HTML or XML file.

  • /XML Formats the report file as XML.

  • /DURATION<SECONDS> Specifies the number of seconds to observe system behavior. Default is 60 seconds.

  • /TRACE Records system behavior and does not perform analysis. Trace files are generated in the current path unless the /D parameter is specified.

  • /D<FILEPATH> Specify the directory to store trace data. May only be used with the /TRACE parameter.

Examples:

POWERCFG /ENERGY
POWERCFG /ENERGY /OUTPUT "longtrace.html" /DURATION 120

See Also

Tasks

Set the Default Power Plan
Create a Custom Power Plan
Fine-Tune a Custom Power Plan

Other Resources

Windows Deployment Command-Line Tools Reference