Skip to content

How-ToOS

Windows Recovery Environment Missing in Windows 11? How to Check and Re-enable WinRE

Reset this PC or Advanced startup not working? Here's how to check whether the Windows Recovery Environment is enabled with reagentc /info, switch it back on with reagentc /enable, and what to do if the recovery image or partition is missing or too small.

By , Systems & Technical Editor

7 min read

Windows Recovery Environment Missing in Windows 11? How to Check and Re-enable WinRE

You usually only discover the Windows Recovery Environment is broken at the worst possible moment: Reset this PC refuses to start, Advanced startup just reboots back to the desktop, or a PC that won't boot never reaches the blue recovery menu. WinRE is the hidden set of repair tools behind Startup Repair, the recovery Command Prompt and the boot-time versions of System Restore and Reset this PC, so it's worth checking it works before you need it. This guide shows how to check its status with one command, switch it back on, and what to do if the recovery image itself is missing or the recovery partition is too small. The commands and behaviour described come from Microsoft's own documentation, and we've said where something is our advice.

What WinRE is and why it matters

Microsoft describes Windows RE as "a set of built‑in Windows tools designed to help troubleshoot and fix common system problems". Its technical documentation says WinRE is "based on Windows Preinstallation Environment (Windows PE)" and is preloaded on Windows 10 and Windows 11 desktop editions, including Home and Pro.

From the WinRE menus you can reach, among other things:

  • Startup Repair, which Microsoft says "automatically diagnoses and repairs common issues that can prevent Windows from starting" (see our guide to using Startup Repair in Windows 11)

  • Reset this PC, with options to keep or remove your personal files (our guide to resetting Windows 11 covers the choices)

  • System Restore and point-in-time restore (our System Restore vs Reset this PC comparison explains the difference)

  • Startup Settings, a Command Prompt and UEFI Firmware Settings

WinRE also starts by itself when something goes wrong. Microsoft lists triggers including "Two consecutive failed attempts to start Windows" and "Two consecutive unexpected shutdowns that occur within two minutes of boot completion". If WinRE is disabled, a PC with a boot problem has no built-in safety net, which is why it's worth a two-minute check now.

Signs WinRE isn't working

Microsoft doesn't publish a single error message for a broken recovery environment, so watch for these symptoms instead:

  • Choosing Restart now next to Advanced startup, or holding Shift while you restart, brings you straight back to Windows instead of the blue Choose an option screen.

  • Reset this PC or another recovery option fails and complains that it can't find the recovery environment.

  • A PC that repeatedly fails to boot never shows the Automatic Repair screen.

If you see any of these, run the check below.

Step 1: Check WinRE's status with reagentc /info

REAgentC is the command-line tool built into Windows for managing the recovery environment. Microsoft says it can "configure a Windows Recovery Environment (Windows RE) boot image and a push-button reset recovery image".

  1. Right-click the Start button and choose Terminal (Admin), or search for Command Prompt and select Run as administrator.

  2. Type reagentc /info and press Enter.

Microsoft says /info "Displays the current status of Windows RE and any available recovery image". Look at two things in the output:

  • Status. It will show Windows RE as enabled or disabled.

  • Location. Microsoft's KB5028997 says that if WinRE is installed, "there should be a “Windows RE location” with a path to the WinRE directory". The path includes harddisk and partition numbers. Microsoft explains that "the number after “harddisk” and “partition” is the index of the disk and partition WinRE is on". Make a note of them.

If the status is enabled and there's a location, WinRE is configured. If it's disabled, or the location is blank, carry on.

Step 2: Turn WinRE back on with reagentc /enable

In the same admin window, run:

reagentc /enable

Then run reagentc /info again to confirm. Microsoft's documentation for the /enable option says that if you don't point it at a specific image, "the computer attempts to enable Windows RE by using the default Winre.wim file from the \Windows\System32\Recovery folder". In other words, Windows keeps a copy of the recovery image inside the Windows folder and can move it back into place itself.

On many PCs that's all it takes. Once reagentc /info shows WinRE as enabled with a location, test it: go to Settings > System > Recovery and, next to Advanced startup, select Restart now. Microsoft's alternative is to "press and hold the Shift key while you select Power > Restart". You should land on the blue recovery menu. Choose Continue to go back to Windows.

Step 3: If reagentc /enable fails

If /enable returns an error, two likely culprits are a missing Winre.wim image or a missing recovery partition. Here's how we'd work through it:

  • Check you're in an admin window. REAgentC changes system configuration, so it needs elevation.

  • Check the partition layout. Open Disk Management (right-click Start > Disk Management) and look for a small partition labelled Recovery on your Windows drive. Microsoft's KB5028997 describes WinRE living on its own recovery partition on the same disk as Windows. If that partition has been deleted, for example by a partition tool or when moving Windows to a new SSD, WinRE may have nowhere to live.

  • Don't delete or format recovery partitions to free space. They're small, and removing them is an easy way to end up here.

If the Winre.wim file itself is gone, there's no simple one-line fix. The two practical routes are:

  1. An in-place repair install. A repair install reinstalls Windows while keeping your files and apps. It's the most thorough fix we'd try short of a clean install, and you should run reagentc /info again afterwards to check the result. Our guide to a repair install of Windows 11 that keeps your files walks through it. Back up first.

  2. Use external recovery media instead. Microsoft says that if you've created a USB recovery drive, booting from it "will take you directly to Windows RE", and that installation media made with the Media Creation Tool "can then be used to boot into Windows RE" too. That doesn't repair the built-in copy, but it gives you a working set of recovery tools. See our guides to creating a recovery drive in Windows 11 and making a Windows 11 installation USB.

Our advice is to make a recovery drive whatever happens. It costs you a spare USB stick and is the backup plan if WinRE breaks again.

Step 4: If the recovery partition is too small

Since June 2023, Microsoft has updated WinRE through the monthly cumulative update. KB5028997 warns that "Some PCs might not have a recovery partition that is large enough to complete this update". It says that if you see a system event with ID 4502 reading "Windows Recovery Environment servicing failed." with an ErrorPhase of 2, a lack of space on the recovery partition is the likely cause. You can look for that event in the System log using Event Viewer.

Microsoft's fix is to make the recovery partition 250 MB bigger. In outline, the procedure in KB5028997 is:

  1. Run reagentc /info to find the disk and partition WinRE is on, then reagentc /disable.

  2. In diskpart, shrink the Windows partition with shrink desired=250 minimum=250.

  3. Delete the old recovery partition and create a new one in the freed space, with a different command for GPT and MBR disks, then format it as NTFS.

  4. Exit diskpart and run reagentc /enable, then reagentc /info to confirm.

These steps delete and create partitions, and selecting the wrong partition number can wipe data. If you go ahead, follow Microsoft's KB5028997 page line by line rather than our summary, and back up first. Microsoft also notes that if creating the partition fails, or you decide not to extend it, you can simply run reagentc /enable to re-enable WinRE. Microsoft lists Windows 11 versions 21H2, 22H2 and 23H2 among the versions the KB applies to. Newer versions aren't listed, so check the page is still current for your PC before you start.

Before you use WinRE: BitLocker and admin rights

Two things catch people out once WinRE is working again:

  • BitLocker. Microsoft says that if you've encrypted your device, "you’ll need the BitLocker recovery key to use certain tools". If your PC uses BitLocker or device encryption, find your key now with our guide to finding your BitLocker recovery key.

  • Admin accounts. Microsoft notes that in Windows 11 "You can now run most tools within WinRE without selecting an administrator account and entering the password", but encrypted files stay locked without the key.

Windows 11 also has newer recovery features that run from WinRE, such as quick machine recovery and cloud rebuild, which need a network connection. Our guide to quick machine recovery in Windows 11 explains it.

The bottom line

If Windows 11's recovery tools won't open, run reagentc /info in an admin Terminal to check whether the Windows Recovery Environment is enabled and where it lives. If it's disabled, run reagentc /enable, which uses the copy of Winre.wim in \Windows\System32\Recovery, then test it with Settings > System > Recovery > Advanced startup > Restart now. If enabling fails because the image or recovery partition is missing, a repair install or a USB recovery drive gets you working recovery tools. If updates fail with event 4502, follow Microsoft's KB5028997 to enlarge the recovery partition, and back up first.

Sources

  1. 01REAgentC command-line options (Microsoft Learn)
  2. 02Windows Recovery Environment (Windows RE) (Microsoft Learn)
  3. 03Windows recovery environment (Microsoft Support)
  4. 04KB5028997: Instructions to manually resize your partition to install the WinRE update (Microsoft Support)
  5. 05Recovery options in Windows (Microsoft Support)

About the author

Marcus Thorne

Systems & Technical Editor

Marcus writes Forge PC's step-by-step build, troubleshooting and system optimisation guides. His background spans Windows kernel and power-state diagnostics, UEFI/BIOS configuration, NVMe storage arrays, ATX 3.1 power delivery and running local AI and LLM workloads on consumer graphics cards.

More from Marcus Thorne

Read next

How to Customise a DualSense Edge Controller on a PC Without a PS5

How-To

How to Customise a DualSense Edge Controller on a PC Without a PS5

Sony's PlayStation Accessories app lets you set up a DualSense Edge on a Windows PC without a PS5. We explain how to create profiles, remap the back buttons, tune stick curves, dead zones and triggers, and switch profiles in game.

Marcus Thorne6 min

How to Update a PS5 DualSense Controller's Firmware on a Windows PC

How-To

How to Update a PS5 DualSense Controller's Firmware on a Windows PC

You don't need a PS5 to update a DualSense or DualSense Edge controller. Sony's free PlayStation Accessories app for Windows checks the firmware and installs updates over USB or Bluetooth. We explain what you need, the steps and what to do if it goes wrong.

Marcus Thorne6 min