This tutorial will show you how to change the default action to take when closing the lid of your laptop in Windows 10 and Windows 11.
The lid switch close action specifies the action to take when the system lid is closed.
Users can specify one of the following actions to take:
- Do Nothing = No action is taken when the system lid is closed.
- Sleep = The system enters sleep when the system lid is closed.
- Hibernate = The system enters hibernate when the system lid is closed.
- Shut Down = The system shuts down when the system lid is closed.
- Option One: Change Lid Close Action for Current Power Plan in Settings
- Option Two: Change Lid Close Action for Current Power Plan in Power Options
- Option Three: Change Lid Close Action for Specific Power Plan in Advanced Power Options
- Option Four: Change Lid Close Action for Current Power Plan in Windows Terminal
- Option Five: Change Lid Close Action for Specific Power Plan in Windows Terminal
- Option Six: Specify Lid Close Action for All Power Plans in Local Group Policy Editor
- Option Seven: Specify Lid Close Action for All Power Plans using REG file
This option is only available starting with Windows 11 version 24H2.
1 Open Settings (Win+I).
2 Click/tap on System on the left side, and click/tap on Power & battery on the right side. (see screenshot below)
3 Click/tap on Lid & power button controls to expand it open. (see screenshot below)
4 Select Do Nothing, Sleep (default), Hibernate, Shutdown, or Display Off for what you want in the "Plugged in" and "On battery" Closing the lid will make my PC drop menus.
5 You can now close Settings if you like.
1 Open the Control Panel (icons view), and click/tap on the Power Options icon.
2 Click/tap on the Choose what the power button does link in the left pane. (see screenshot below)
3 In both the On battery and Plugged in drop menus for the When I close the lid setting, select Do nothing, Sleep (default), Hibernate, or Shut down for what you want, and click/tap on Save changes.
Desktop computers will not have separate On battery and Plugged in options available unless it has a data connection to a UPS.
1 Open the Control Panel (icons view), and click/tap on the Power Options icon.
2 Click/tap on the Change plan settings link for the power plan (ex: "Balanced") you want to apply this to. (see screenshot below)
3 Click/tap on the Change advanced power settings link. (see screenshot below)
4 Expand open the Power buttons and lid and Lid close action settings. (see screenshot below step 5)
You can add Lid close action to Power Options if you do not have it available.
5 In both the On battery and Plugged in drop menus for the Lid close action setting, select Do nothing, Sleep (default), Hibernate, or Shut down for what you want, and click/tap on OK.
Desktop computers will not have separate On battery and Plugged in options available unless it has a data connection to a UPS.
1 Open Windows Terminal, and select either Windows PowerShell or Command Prompt.
2 Copy and paste the command below you want to use for when on battery and/or plugged in into Windows Terminal, and press Enter.
powercfg -setdcvalueindex SCHEME_CURRENT 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 0
powercfg -setdcvalueindex SCHEME_CURRENT 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 1
powercfg -setdcvalueindex SCHEME_CURRENT 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 2
powercfg -setdcvalueindex SCHEME_CURRENT 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 3
You would use this option for a desktop computer, since desktop computers will not have separate On battery and Plugged in options available unless it has a data connection to a UPS.
powercfg -setacvalueindex SCHEME_CURRENT 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 0
powercfg -setacvalueindex SCHEME_CURRENT 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 1
powercfg -setacvalueindex SCHEME_CURRENT 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 2
powercfg -setacvalueindex SCHEME_CURRENT 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 3
3 You can now close Windows Terminal if you like.
1 Open Windows Terminal, and select either Windows PowerShell or Command Prompt.
2 Copy and paste the
powercfg /L
command into Windows Terminal, and press Enter. Make note of the GUID number (ex: 381b4222-f694-41f0-9685-ff5bb260df2e) of the power plan (ex: "Balanced") you want to apply this to. (see screenshot below)The power plan (ex: Ultimate Performance) with an asterisk (*) to the right of it is your current active power plan scheme.
3 Type the command below you want to use for when on battery and/or plugged in into Windows Terminal, and press Enter.
powercfg -setdcvalueindex GUID 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 0
powercfg -setdcvalueindex GUID 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 1
powercfg -setdcvalueindex GUID 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 2
powercfg -setdcvalueindex GUID 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 3
You would use this option for a desktop computer, since desktop computers will not have separate On battery and Plugged in options available unless it has a data connection to a UPS.
powercfg -setacvalueindex GUID 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 0
powercfg -setacvalueindex GUID 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 1
powercfg -setacvalueindex GUID 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 2
powercfg -setacvalueindex GUID 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 3
Substitute GUID in the command above with the actual GUID from step 2 above for the power plan you want to apply this to.
For example: Set to "Shut down" while "Plugged in" for the Balanced power plan GUID (381b4222-f694-41f0-9685-ff5bb260df2e)
powercfg -setacvalueindex 381b4222-f694-41f0-9685-ff5bb260df2e 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 3
4 You can now close Windows Terminal if you like.
You must be signed in as an administrator to use this option.
The Local Group Policy Editor is only available in the Windows 11 Pro, Enterprise, and Education, editions.
All editions can use Option Seven below to configure the same policy.
1 Open the Local Group Policy Editor (gpedit.msc).
2 Navigate to the policy location below in the left pane of the Local Group Policy Editor. (see screenshot below)
3 In the right pane of Button Settings, double click/tap on the Select the lid switch action (plugged in) and/or Select the lid switch action (on battery) policy you want to edit. (see screenshot above)
4 Do step 5 (default), step 6 (hibernate), step 7 (shut down), step 8 (sleep), or step 9 (Take no action) below for which default action you want to specify.
This will allow users to use Option One, Option Two, Option Three, and Option Four.
This will override and gray out Option One, Option Two, Option Three, Option Four, and Option Five.
This will override and gray out Option One, Option Two, Option Three, Option Four, and Option Five.
This will override and gray out Option One, Option Two, Option Three, Option Four, and Option Five.
This will override and gray out Option One, Option Two, Option Three, Option Four, and Option Five.
10 When finished, you can close the Local Group Policy Editor if you like.
You must be signed in as an administrator to use this option.
1 Do step 2 (default), step 3 (hibernate), step 4 (shut down), step 5 (sleep), or step 6 (Take no action) below for which default action you want to specify.
This will allow users to use Option One, Option Two, Option Three, Option Four, and Option Five.
(Contents of REG file for reference)
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Power\PowerSettings\5CA83367-6E45-459F-A27B-476B1D01C936]
"ACSettingIndex"=-
(Contents of REG file for reference)
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Power\PowerSettings\5CA83367-6E45-459F-A27B-476B1D01C936]
"DCSettingIndex"=-
This will override and gray out Option One, Option Two, Option Three, Option Four, and Option Five.
(Contents of REG file for reference)
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Power\PowerSettings\5CA83367-6E45-459F-A27B-476B1D01C936]
"ACSettingIndex"=dword:00000002
(Contents of REG file for reference)
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Power\PowerSettings\5CA83367-6E45-459F-A27B-476B1D01C936]
"DCSettingIndex"=dword:00000002
This will override and gray out Option One, Option Two, Option Three, Option Four, and Option Five.
(Contents of REG file for reference)
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Power\PowerSettings\5CA83367-6E45-459F-A27B-476B1D01C936]
"ACSettingIndex"=dword:00000003
(Contents of REG file for reference)
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Power\PowerSettings\5CA83367-6E45-459F-A27B-476B1D01C936]
"DCSettingIndex"=dword:00000003
This will override and gray out Option One, Option Two, Option Three, Option Four, and Option Five.
(Contents of REG file for reference)
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Power\PowerSettings\5CA83367-6E45-459F-A27B-476B1D01C936]
"ACSettingIndex"=dword:00000001
(Contents of REG file for reference)
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Power\PowerSettings\5CA83367-6E45-459F-A27B-476B1D01C936]
"DCSettingIndex"=dword:00000001
This will override and gray out Option One, Option Two, Option Three, Option Four, and Option Five.
(Contents of REG file for reference)
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Power\PowerSettings\5CA83367-6E45-459F-A27B-476B1D01C936]
"ACSettingIndex"=dword:00000000
(Contents of REG file for reference)
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Power\PowerSettings\5CA83367-6E45-459F-A27B-476B1D01C936]
"DCSettingIndex"=dword:00000000
7 Save the .reg file to your desktop.
8 Double click/tap on the downloaded .reg file to merge it.
9 When prompted, click/tap on Run, Yes (UAC), Yes, and OK to approve the merge.
10 You can now delete the downloaded .reg file if you like.
That's it,
Shawn Brink
Attachments
-
Default_user_choice_for_lid_close_action-on-battery.reg636 bytes · Views: 322
-
Default_user_choice_for_lid_close_action-plugged-in.reg636 bytes · Views: 392
-
Specify_do_nothing_for_lid_close_action-on-battery.reg662 bytes · Views: 385
-
Specify_do_nothing_for_lid_close_action-plugged-in.reg662 bytes · Views: 496
-
Specify_hibernate_for_lid_close_action-on-battery.reg662 bytes · Views: 283
-
Specify_hibernate_for_lid_close_action-plugged-in.reg662 bytes · Views: 304
-
Specify_shut_down_for_lid_close_action-on-battery.reg662 bytes · Views: 271
-
Specify_shut_down_for_lid_close_action-plugged-in.reg662 bytes · Views: 291
-
Specify_sleep_for_lid_close_action-plugged-in.reg662 bytes · Views: 328
-
Specify_sleep_for_lid_closeaction-on-battery.reg662 bytes · Views: 301