Skip to content

How-ToOS

How to Stop Your PC Waking Up From Sleep on Its Own

If Windows wakes itself up, run powercfg /lastwake to see why. Then use powercfg to list and disarm wake-capable devices, check wake timers and requests, turn off Allow wake timers, and look at your BIOS power settings.

By , Editorial team

3 min read

How to Stop Your PC Waking Up From Sleep on Its Own

You put your PC to sleep, and an hour later the fans are spinning and the screen is on. Usually something told it to wake up: a mouse or keyboard, the network adapter, a scheduled task or a wake timer. Windows has a built-in tool, powercfg, that can tell you which. This guide uses Microsoft's documentation for powercfg and Windows maintenance; Forge PC hasn't tested every scenario on every PC.

Step 1: Open an administrator terminal

Right-click the Start button and choose Terminal (Admin), or search for Command Prompt, right-click it and choose Run as administrator. We suggest using an administrator window for all the commands below.

Step 2: Find out what woke the PC last time

Type:

powercfg /lastwake

Microsoft says this reports what woke the system from the last sleep transition. Run it straight after an unexpected wake, before the PC sleeps again.

Step 3: List devices that are allowed to wake the PC

Type:

powercfg /devicequery wake_armed

Microsoft says this lists the devices currently configured to wake the system from any sleep state.

Step 4: Stop a device waking the PC

If the culprit is your mouse, for example, disable its wake permission using the exact name from the list:

powercfg /devicedisablewake "Device name"

Microsoft's example uses "Microsoft USB IntelliMouse Optical". To let a device wake the PC again, use powercfg /deviceenableawake "Device name"; powercfg /devicequery wake_programmable lists every device you can configure. Keep your keyboard able to wake the PC so you can still wake it without the power button.

Step 5: Check the network adapter and Wake-on-LAN

If your network adapter appears in the wake-armed list and you don't use Wake-on-LAN, you can disable wake for the adapter with the command above. If you do use it, our Wake-on-LAN guide explains how to set it up so it only responds to the right signal.

Step 6: Check wake timers

Type:

powercfg /waketimers

Microsoft says this lists active wake timers, and that when a timer expires it wakes the system from sleep and hibernate. Microsoft's Task Scheduler documentation says a task must be allowed to wake the machine, and lists the Allow wake timers setting in Power Options as one of the things to check. To stop timers waking the PC, open Power Options and turn that setting off for your power plan.

Step 7: Understand Windows maintenance

Windows runs automatic maintenance tasks through Task Scheduler. Microsoft's documentation says the older approach used a daily maintenance window, by default 3am, when the machine could wake from standby, run tasks and go back to sleep. Microsoft says Task Scheduler now runs maintenance tasks when they're due and the machine is idle and on mains power, and that whether a wake happens depends on how your PC and tasks are configured. If powercfg /lastwake or /waketimers points to a maintenance task, turning off wake timers (Step 6) is the simplest fix.

Step 8: Check your BIOS

Microsoft's guidance on scheduled wakes also says to check your BIOS settings for wake options. If you've ruled out Windows, look for wake-related options in your board's power settings and check its manual. Our guide to updating the BIOS safely explains how to get into it and update it if needed.

The opposite problem: PC won't go to sleep

If your PC never sleeps, run:

powercfg /requests

Microsoft says this lists application and driver power requests, which stop the computer from turning off the display or going to sleep. Microsoft's own override example uses Windows Media Player (wmplayer.exe). powercfg /requestsoverride can tell Windows to ignore a specific request.

Sleep or hibernate?

If you'd rather the PC didn't wake at all overnight, shutting it down is the surest option. Our sleep vs hibernate explainer covers the differences, and how to disable Fast Startup explains a related setting that affects how Windows shuts down. For power plans generally, see how to change power mode in Windows 11.

Our verdict

Run powercfg /lastwake after an unexpected wake to see what caused it, then use /devicequery wake_armed and /devicedisablewake to stop devices waking the PC, /waketimers and the Allow wake timers setting to stop scheduled wakes, and check the BIOS if Windows looks clear.

The bottom line

Run `powercfg /lastwake` after an unexpected wake to see what caused it, then use `/devicequery wake_armed` and `/devicedisablewake` to stop devices waking the PC, `/waketimers` and the Allow wake timers setting to stop scheduled wakes, and check the BIOS if Windows looks clear.

Sources

  1. 01Microsoft Learn, Powercfg command-line options
  2. 02Microsoft Learn, Task Maintenance (Task Scheduler)

About the author

Forge PC Staff

Editorial team

The shared byline for articles researched, written and edited by the Forge PC editorial team. How we source, check and correct our work is set out in our editorial policy.

More from Forge PC Staff

Read next

How to Connect a PS5 DualSense Controller to Your PC

How-To

How to Connect a PS5 DualSense Controller to Your PC

A PS5 DualSense connects to a Windows PC by USB-C or Bluetooth. PlayStation says haptics and the headset jack need a cable on PC; to pair wirelessly, hold Create and PS until the light bar blinks, then add it in Windows.

Forge PC Staff3 min

How to Use Ollama With n8n for Local AI Workflows

How-To

How to Use Ollama With n8n for Local AI Workflows

Run n8n in Docker, make Ollama listen on 0.0.0.0, and set the n8n Ollama credential's Base URL to http://host.docker.internal:11434. A Chat Trigger, Basic LLM Chain and Ollama Chat Model then make a first local AI workflow.

Forge PC Staff4 min

Best Free Keyboard and Mouse Remapping Software for Windows

Best Picks

Best Free Keyboard and Mouse Remapping Software for Windows in 2026

PowerToys Keyboard Manager is the best free remapping tool for most people. SharpKeys makes permanent key swaps with nothing running in the background, X-Mouse Button Control handles mouse buttons and per-app profiles, and AutoHotkey covers macros.

Forge PC Staff4 min