

To also disable Hibernate mode (standby state S4) run powercfg. This policy will disable all sleep modes completely.


WinWaitActive( "Local Group Policy Editor") Since I needed to enable / disable sleep mode via Group Policy quite often, I created quick and dirty AutoIt script that opens Local Group Policy Editor and navigates to the correct GP: If necessary also do the same for Allow Standby States (S1-S3) When Sleeping (On Battery) You can of course go to the Power Options in Control Panel and create or edit a power plan that keeps the computer and display on.Open Policy called Allow Standby States (S1-S3) When Sleeping (Plugged In) and set value do Disabled.Navigate to Computer Configuration > Administrative Templates > System > Power Management > Sleep Settings.Launch Local Group Policy Editor (gpedit.msc).To disable sleep mode completely you can use Local Group Policy:
