Windows Hacks

created 16. January. 2025

Windows wakes up from sleep/hibernation mode

The beauty of Windows' sleep / hibernation mode is that you can seamlessly interrupt your work and still save electricity by powering the PC down while you're away.

Sadly this doesn't work flawlessly and there are often times when connected devices (like mice, keyboards,...) unintentionally wake the PC up again.

There are standard powercfg commands where you can check what caused such a random power-on:

While they can sometimes show the culprit, they can also simply turn up blank.

PS C:\WINDOWS\system32> powercfg waketimers
There are no active wake timers in the system.
PS C:\WINDOWS\system32> powercfg lastwake
Wake History Count - 1
Wake History [0]
Wake Source Count - 0

This is where the wake_armed option comes in, which shows you which devices can potentially wake up your PC in the first place.

Armed with this knowledge you can then go in and disable the wakeup option for the affected devices via the devicedisablewake option:

PS C:\WINDOWS\system32> powercfg -devicequery wake_armed
NVIDIA USB Type-C Port Policy Controller
Intel(R) Ethernet Controller I226-V

PS C:\WINDOWS\system32> powercfg -devicedisablewake "NVIDIA USB Type-C Port Policy Controller"
PS C:\WINDOWS\system32> powercfg -devicedisablewake "Intel(R) Ethernet Controller I226-V"