Windows slow boot: diagnose and fix it from the command line
A step-by-step CLI guide to finding out why Windows starts slowly — boot config, event log errors, startup bloat — and the fixes that actually help.
What this covers
A slow boot usually comes down to three things: the boot configuration itself, services that fail or hang during startup, and the pile of programs and services set to launch automatically. This guide walks you through diagnosing each from the command line, applying the fixes that match what you find, and verifying with a timed reboot.
Symptom
Inspect the boot configuration first
Slow boot is often a boot-configuration problem: a long menu timeout, extra loader entries, or leftover debugging settings. Read the BCD store before changing anything so you know what your baseline looks like. You're looking for an unexpectedly large timeout value under the Windows Boot Manager, duplicate loader entries, or unusual flags. If nothing looks wrong here, the delay is happening after the boot manager hands off to Windows.
Read the BCD store's boot manager and loader entries before making any boot changes.
$ bcdedit /enumCheck the System event log for boot-time errors
Services that fail or time out during startup are a classic cause of a slow boot — Windows waits for each one before continuing. Pull the 20 most recent errors from the System log and look for entries timestamped around your last boot, especially service timeouts or disk-related errors. Recurring errors here point you at the specific component that is stalling startup.
Query the System or Application log for errors, newest first, without opening Event Viewer.
$ wevtutil qe System /q:"*[System[(Level=2)]]" /c:20 /rd:true /f:textList the programs that launch at startup
Autostart entries from Run keys and Startup folders all compete for disk and CPU during logon, which is often perceived as 'slow boot'. Enumerate everything that launches automatically and look for anything you don't recognize or no longer need — old updaters, vendor bloatware, leftover uninstallers. Seeing the full list tells you whether logon bloat is the problem.
Enumerate autostart entries from Run keys and Startup folders — a forgotten WMI class for spotting unwanted startup software.
$ Get-CimInstance Win32_StartupCommand | Select-Object Name, Command, Location, User | Format-Table -AutoSize -WrapCount the services set to start automatically
Services set to Automatic all start before you reach the desktop, and each one adds delay — especially if one hangs. List every Automatic service with its status and cross-reference it against the errors you found in the event log. A service that is set to Automatic but stuck in 'Starting' is your prime suspect.
Use Get-Service filtered on StartType to see every service set to Automatic.
$ Get-Service | Where-Object StartType -eq Automatic | Select-Object Name, DisplayName, StatusShorten the boot menu timeout
If your bcdedit /enum output showed a large timeout, every boot is silently wasting those seconds at the boot menu even on a single-OS machine. Reduce it to 5 seconds so startup moves on quickly. To undo, restore the default with the provided undo command. Skip this step if your timeout was already short.
Shorten or lengthen how long Windows shows the dual-boot / recovery menu at startup using bcdedit /timeout.
$ bcdedit /timeout 5▾ Undo
$ bcdedit /timeout 30Install pending Windows updates
Pending updates can make every boot slower: Windows may apply or retry them at startup, and outdated drivers or servicing-stack bugs are common boot-performance culprits. Search for, install, and reboot into all available updates from PowerShell. When the machine reboots cleanly into a fully patched state, this common cause is ruled out.
Search, download, install, and reboot into updates without opening Settings — ideal for RDP sessions and scripting.
$ Install-Module PSWindowsUpdate -Force
Get-WindowsUpdate
Install-WindowsUpdate -AcceptAll -AutoRebootReboot and measure the new boot time
The only honest verification is a timed reboot. Restart the machine, then check the last boot timestamp and uptime — combined with the clock on your watch or phone, this tells you whether startup is now faster than your original baseline. If the boot is still slow, revisit the event-log errors: the stalling component should now appear with a clearer trace.
Get Windows uptime and last boot timestamp using PowerShell's Get-CimInstance with Win32_OperatingSystem, the modern replacement for the deprecated wmic.
$ $os = Get-CimInstance Win32_OperatingSystem
$os.LastBootUpTime
(Get-Date) - $os.LastBootUpTimeHow to confirm it worked
After applying fixes, restart and time the boot. Check the last boot timestamp and uptime to compare against your baseline — startup should be measurably faster and the System event log should show no new boot-time errors.
Undo everything
Every command above can be reverted. Run these in order to undo all of it.
$ bcdedit /timeout 30Review before running — some steps may not be independent.
Sources
- bcdedit - Windows CommandsEvidence: Documents bcdedit, including /enum which lists entries in the Boot Configuration Data store, and the warning to run elevated.
- wevtutil - Windows CommandsEvidence: Documents wevtutil, including the query-events (qe) command with /q XPath filter, /c count, /rd reverse direction and /f text format.
- Win32_StartupCommand classEvidence: Describes the Name, Command, Location, and User properties of startup entries.
- Get-ServiceEvidence: Get-Service returns ServiceController objects for all services (no arguments = every service), which can be piped to Where-Object for filtering by properties such as Status.
- ServiceController.StartType PropertyEvidence: Documents the StartType property of ServiceController objects (the type returned by Get-Service) and the ServiceStartType enumeration values Automatic, Manual and Disabled.
- BCDEdit - Boot Configuration Data - SS64Evidence: Documents the /timeout option that controls the boot menu wait time in seconds.
- PSWindowsUpdateEvidence: Module page documenting Get-WindowsUpdate and Install-WindowsUpdate cmdlets built on the Windows Update Agent API.
- Get-CimInstance - SS64Evidence: Get-CimInstance retrieves WMI/CIM class instances and supports date conversion of CIM timestamps.
Last verified: 2026-09-21
Related guides
Generate a Windows battery report with powercfg, check live charge status, and trace what is draining power — all from the terminal.
Windows hangs on shutdown or never powers off? Diagnose it from the event log, cancel stuck shutdown timers, disable Fast Startup and verify a clean shutdown from the command line.
Work through repeating System and Application errors in the right order: query the log properly, look at the other places errors hide, then confirm the noise actually stops.