Published by


Brink's Avatar
Administrator

Posts: 16,510

Show Printable Version 


How to Change Default Action of Power Button in Windows 10

information   Information
In Windows 10, you can specify in each power plan the default action to take when users press the power button on the PC to either do nothing, sleep, hibernate, shut down, or turn off the display.

This tutorial will show you how to change the default action to take when users press the PC case power button in Windows 10.


CONTENTS:
  • Option One: To Change Default Power Button Action in Power Options
  • Option Two: To Change Default Power Button Action in Advanced Power Options
  • Option Three: To Change Default Power Button Action for Current Power Plan in Command Prompt
  • Option Four: To Change Default Power Button Action for Specific Power Plan in Command Prompt





Power Button Default Action - Change in Windows 10 OPTION ONE Power Button Default Action - Change in Windows 10
To Change Default Power Button Action in Power Options

1. Open Power Options. (see screenshot below)

Click image for larger version. 

Name:	open_Power_Options.jpg 
Views:	13 
Size:	63.6 KB 
ID:	110000

2. Click/tap on the Choose what the power buttons do or Choose what the power button does link on the left side. (see screenshot below)

Click image for larger version. 

Name:	Change_Power_button_action-1.png 
Views:	12 
Size:	32.3 KB 
ID:	109997

3. In the When I press the power button drop menus, select the action you want, and click/tap on Save changes. (see screenshot below)

Click image for larger version. 

Name:	Change_Power_button_action-2.png 
Views:	9 
Size:	49.5 KB 
ID:	109998






Power Button Default Action - Change in Windows 10 OPTION TWO Power Button Default Action - Change in Windows 10
To Change Default Power Button Action in Advanced Power Options

1. Open Advanced Power Options.

2. Expand open Power buttons and lid and Power button action. (see screenshot below)

3. Select the action you want, and click/tap on OK. (see screenshot below)

Name:  Change_Power_button_action-3.png
Views: 105
Size:  30.1 KB






Power Button Default Action - Change in Windows 10 OPTION THREE Power Button Default Action - Change in Windows 10
To Change Default Power Button Action for Current Power Plan in Command Prompt

1. Open a command prompt.

2. Enter the command below you want to use into the command prompt, and press Enter. (see screenshot below)

(On battery)
Code:
powercfg -setdcvalueindex SCHEME_CURRENT 4f971e89-eebd-4455-a8de-9e59040e7347 7648efa3-dd9c-4e3e-b566-50f929386280 Index

OR

(Plugged in)
Code:
powercfg -setacvalueindex SCHEME_CURRENT 4f971e89-eebd-4455-a8de-9e59040e7347 7648efa3-dd9c-4e3e-b566-50f929386280 Index
Note   Note
Substitute Index in the command above with the number below for the default action you want set for the power button.

Index Number Action
0 Do nothing
1 Sleep
2 Hibernate
3 Shut down
4 Turn off the display

For example:

Code:
powercfg -setacvalueindex SCHEME_CURRENT 4f971e89-eebd-4455-a8de-9e59040e7347 7648efa3-dd9c-4e3e-b566-50f929386280 0

3. Enter the command below into the command prompt, and press Enter to apply the change. You can now close the command prompt if you like.

powercfg -SetActive SCHEME_CURRENT

Click image for larger version. 

Name:	current_power_button_command.png 
Views:	6 
Size:	17.6 KB 
ID:	110557






Power Button Default Action - Change in Windows 10 OPTION FOUR Power Button Default Action - Change in Windows 10
To Change Default Power Button Action for Specific Power Plan in Command Prompt

1. Open a command prompt.

2. Enter the command below into the command prompt, and press Enter. Make note of the GUID number (ex: 8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c) of the power plan you want to apply this to. (see screenshot below)
Note   Note
The power plan (ex: High performance) with a * to the right of it is your current active power plan scheme.


powercfg /L

Click image for larger version. 

Name:	Change_Power_button_action_command-1.png 
Views:	6 
Size:	23.8 KB 
ID:	110001

3. Enter the command below you want to use into the command prompt, and press Enter. (see screenshot below)

(On battery)
Code:
powercfg -setdcvalueindex GUID 4f971e89-eebd-4455-a8de-9e59040e7347 7648efa3-dd9c-4e3e-b566-50f929386280 Index

OR

(Plugged in)
Code:
powercfg -setacvalueindex GUID 4f971e89-eebd-4455-a8de-9e59040e7347 7648efa3-dd9c-4e3e-b566-50f929386280 Index
Note   Note
Substitute GUID in the command above with the actual GUID from step 2 above for the power plan you want to apply this to.

Substitute Index in the command above with the number below for the default action you want set for the power button.

Index Number Action
0 Do nothing
1 Sleep
2 Hibernate
3 Shut down
4 Turn off the display

For example: Set to "Do nothing" for the High performance power plan GUID (8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c)

Code:
powercfg -setacvalueindex 8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c 4f971e89-eebd-4455-a8de-9e59040e7347 7648efa3-dd9c-4e3e-b566-50f929386280 0

Click image for larger version. 

Name:	Change_Power_button_action_command-2.png 
Views:	7 
Size:	17.5 KB 
ID:	110002

4. Enter the command below into the command prompt, and press Enter to apply the change. (see screenshot below)
Note   Note
This command will set the power plan for the GUID as your active scheme. If you do not want this power plan to be set as your active scheme, then you can restart the computer to apply the changes instead of doing this step.


powercfg -SetActive GUID

Note   Note
Substitute GUID in the command above with the same GUID from step 2 above for the power plan you want to apply this to.

For example: powercfg -SetActive 8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c


Click image for larger version. 

Name:	Change_Power_button_action_command-3.png 
Views:	11 
Size:	12.5 KB 
ID:	110003


That's it,
Shawn