How To: Stop Windows 10 from sleeping after a few minutes of inactivity

PC on? Make a coffee? PC sleeping when you return? Infuriating… I’d already fixed this once after hours of googling, then installed some updates and it’s back to doze-town should I not constantly pay attention to the machine. Here’s how to fix it:

  1. Launch regedit as Administrator (right-click “Run as administrator”).
  2. Go to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Power\PowerSettings\238C9FA8-0AAD-41ED-83F4-97BE242C8F20\7bc4a2f9-d8fc-4469-b07b-33eb785aaca0
  3. Double click on the Attributes key give it the value 2.
  4. Go to Advanced power settings (click on Windows button, write “power options”, click on “Power & sleep settings”, in the selected plan click on “Change plan settings” then “Change advanced power settings”.
  5. Find the Sleep | System unattended sleep timeout option then change the value from 2 Minutes to 20 minutes or such (or indeed 9999).