PC Won't Wake From Sleep, or Wakes Up by Itself at Night? Fix It with powercfg

You put the PC to sleep, and at 3 a.m. it wakes up by itself with the fans spinning. Or the opposite: you shake the mouse and the screen never comes back, so you have to hold the power button. The built-in powercfg command tells you the cause right away.
First: find out what woke the PC
- Right-click Start → Terminal (Admin).
powercfg /lastwake: shows the device or event that last woke the PC.powercfg /devicequery wake_armed: lists devices allowed to wake the PC. Usually the mouse, keyboard and network adapter.powercfg /waketimers: shows scheduled tasks set to wake the PC.
If the PC turns on by itself at night
- The network adapter (most common): Device Manager → Network adapters → double-click your adapter → Power Management tab. Turn off "Allow this device to wake the computer", or leave on only "Only allow a magic packet to wake the computer".
- You can also turn off a device with a command:
powercfg /devicedisablewake "device name"(use the name exactly as it appears in the wake_armed list). - Disable wake timers: Control Panel → Power Options → Change plan settings → Change advanced power settings → Sleep → Allow wake timers → "Disable".
- Automatic maintenance: Control Panel → Security and Maintenance → Maintenance → Change maintenance settings, then untick "Allow scheduled maintenance to wake up my computer at the scheduled time".
If the PC won't wake up from sleep
- Let the keyboard and mouse wake it: in Device Manager, open your device under Keyboards and Mice and other pointing devices, and on the Power Management tab turn on "Allow this device to wake the computer". With a wireless receiver, try a different USB port.
- Update the graphics driver: often the PC is awake but the screen stays black. Install the latest driver from the NVIDIA, AMD or Intel website.
- Find what blocks sleep: if the PC never goes to sleep at all, run
powercfg /requeststo see which program is keeping it awake. - Check supported sleep states:
powercfg /alists the sleep modes your PC supports. If a newer laptop using "Modern Standby (S0)" has frequent problems, thepowercfg /sleepstudyreport shows what drained the battery. - Turn off Fast startup: Control Panel → Power Options → Choose what the power buttons do → "Change settings that are currently unavailable" → untick "Turn on fast startup". This can reduce sleep and shutdown glitches.
Still not fixed?
- Check your motherboard (BIOS) settings for options like "Wake on LAN", "USB Wake" or "RTC Alarm" that may be turned on.
- Try Hibernate instead of Sleep. Run
powercfg /hibernate onin an admin terminal and it appears in Power Options.
Blog
- Is Your 144Hz Monitor Stuck at 60Hz? How to Set the Right Refresh Rate in Windows
- YouTube Streams Return to the Billboard Charts in 2027, and Drake Says the Game Is "Cooked"
- Tesla Robotaxi Now Runs 24/7 in Every City · Musk: Optimus Will "Probably" Be Rented, Not Sold
- Got a Blue Screen? How to Read the Stop Code and What to Try First (Windows 10 and 11)
- Can't Switch Keyboard Language in Windows? Fixes for Win + Space, the Language Bar and the Korean Han/Eng Key
- Set Up Dual Monitors Properly: Change the Main Display, Arrangement and Scaling (Windows 11)
- A Security-Testing AI Tool Turned Weapon: FBI Warns ARTEX Can Take Over Company Networks in 3 Hours
- PC Suddenly Slow? Find What Is Using 100% Disk or CPU in Task Manager (Windows 11)