To fix “Could not find the recovery environment” in Windows 10, open an administrator Command Prompt, run reagentc /info, and run reagentc /enable if Windows RE is disabled. Enabling it requires an available recovery image; if that image is missing or registered incorrectly, you need to correct its location or use installation media.
The short version
- Check first: Run
reagentc /infoin an administrator Command Prompt to check Windows RE. - Enable recovery: Run
reagentc /enablewhen Windows RE is disabled and its recovery image is available. - Keep your apps: Start a repair installation from within Windows and select Keep personal files and apps.
- Use external tools: Boot Windows 10 installation media to access recovery tools independently of the installed recovery image.
| Method or option | When it helps | Main condition |
|---|---|---|
| Enable Windows RE | Recovery is disabled | An available recovery image is required |
| Register the image location | An existing image has the wrong registered path | You need its actual folder |
| Disable and reenable Windows RE | An existing configuration needs another attempt | Does not replace a deleted image |
| DISM and SFC | Windows files are corrupted | Recovery image restoration is not guaranteed |
| Technician image restoration | The recovery image is missing | Requires an appropriate deployment image and technician tools |
| Recovery partition resizing | Servicing identifies insufficient space | Requires the specified partition layout |
| Create installation media | You need a Windows USB or ISO | USB creation erases the selected drive |
| Media Creation Tool reinstall | An activated Windows installation still starts | Retention options require compatible installation settings |
| Repair installation from media | You want to retain applications | Start matching media from within Windows |
| External recovery tools | Local recovery is unusable | Opening tools does not repair local Windows RE |
| Clean installation | You need a destructive reinstall fallback | Files, apps, and settings can be removed |
| Existing recovery USB | You have recovery media for the affected device | Recovery removes files, apps, and settings |
| Create a recovery USB | Recovery files work again | Preparation for future recovery |
| Retry Reset this PC | Windows RE has been restored | Keeping files still removes apps and settings |
| Recovery startup controls | You want to access restored recovery tools | Local entry points need usable Windows RE |
| Schedule a recovery boot | You want to test recovery from Command Prompt | Requires usable Windows RE |
| Surface image download | Your Surface has an offered recovery image | A Windows 10 image is model dependent |
| Surface USB restoration | You have the matching Surface recovery image | Restoration removes personal data |
| Dell BIOSConnect | A supported Dell needs to download recovery tools | Availability depends on the model |
Check and enable Windows RE
Search for cmd, right-click Command Prompt, and select Run as administrator. Administrator access is required, so open the elevated window before entering this status command:
reagentc /infoCheck Windows RE status in the output. If it shows Disabled, run:
reagentc /enableCheck the configuration again after the command finishes. Run the following command and confirm that Windows RE status shows Enabled:
reagentc /infoIf a recovery image is available but the configuration still needs attention, you can disable and reenable Windows RE. Microsoft does not promise that cycling the configuration fixes this error, but you can try these commands in order:
reagentc /disablereagentc /enablereagentc /infoIf enabling fails, check the image location next. Repeating the enable command cannot download or replace a deleted recovery image.
Correct or restore the recovery image
Correcting registration helps when a valid Winre.wim exists but Windows has the wrong location recorded. In an administrator Command Prompt, run the following command after replacing the example folder with the actual folder containing your recovery image:
reagentc /setreimage /path S:\Recovery\WindowsREEnable Windows RE after registering the folder, then check its status. Run these commands in order:
reagentc /enablereagentc /infoIf you cannot locate a valid image, continue with file repair or installation media. Registering an empty folder does not supply the missing image.
For a missing image, Microsoft’s technician workflow uses Winre.wim from inside install.wim. It requires a technician environment with Windows ADK and the WinPE add-on, so have a technician select the appropriate Windows image. The deployment example creates a mount folder and mounts the image with these commands:
md C:\mount\windowsDism /Mount-Image /ImageFile:C:\mount\install.wim /Index:1 /MountDir:C:\mount\windowsIn that example, the recovery image is at C:\mount\windows\Windows\System32\Recovery\winre.wim. The technician can copy it into a Windows image that lacks it, then complete deployment and recovery registration. These example paths and the image index are not a universal repair script for your running PC.
Repair corrupted Windows files
DISM and System File Checker repair Windows component and system-file corruption, but they do not guarantee restoration of a deleted recovery partition or missing Winre.wim. To repair Windows using Command Prompt, search for cmd, right-click Command Prompt, and select Run as administrator. Run DISM first:
DISM.exe /Online /Cleanup-image /RestorehealthLet DISM finish before starting System File Checker. Run this command and wait until verification finishes:
sfc /scannowIf Windows Update cannot supply repair files, DISM can use a suitable repair source. Replace the example source path with that source’s location:
DISM.exe /Online /Cleanup-Image /RestoreHealth /Source:C:\RepairSource\Windows /LimitAccessAfter repairing files, run reagentc /info again and enable Windows RE if needed. If recovery remains unavailable, use a repair installation when Windows starts or external recovery media when it does not.
Repair Windows with installation media
A repair installation reinstalls Windows without invoking the broken reset workflow. To retain applications, start setup from within Windows and use matching Windows 10 media. The language, edition, and architecture must be compatible with the retention option you select.
Open Microsoft’s Windows 10 download page and, under Create Windows 10 installation media, select Download Now. Run the tool as administrator and select Accept.
Creating USB installation media erases the drive’s contents, so use a blank USB drive of at least 8 GB. Choose Create installation media for another PC, select Next, and choose the target language, edition, and architecture. Select USB flash drive for USB media or ISO file for an ISO that you can mount or use for DVD creation.
While signed in to Windows, open the installation-media drive in File Explorer and run setup.exe. For an ISO, right-click the file and select Mount before opening setup.exe. Select Yes when prompted.
Retention choices can remove applications or personal files, so back up personal files before reinstalling. Select Change what to keep, choose Keep personal files and apps, then select Next and Install.
On an activated Windows 10 PC that starts normally, you can also run the Media Creation Tool, select Accept, and choose Upgrade this PC now followed by Next. At the installation summary, select Change what to keep to review the available retention choices.
Choosing Keep personal files only removes applications, while choosing Nothing also removes personal files, so back up personal files before proceeding. Choose Keep personal files and apps, Keep personal files only, or Nothing, then select Install. Compatibility determines which retention choices you can use.
Open recovery tools from external media
If local recovery remains unusable, create Windows 10 installation media on a working PC. Connect the USB drive or DVD to the affected computer and boot it through the manufacturer’s boot menu. This gives you a way to recover Windows using a USB drive independently of the installed recovery image.
Select the language and keyboard preferences, then select Next. In Windows 10 setup, select Repair your computer to open the external tools.
External media provides another way to access the Windows recovery environment. Opening those tools does not itself repair the installed Windows RE configuration, and local startup shortcuts cannot recreate a missing image.
Reinstall from external media when necessary
If you already have a recovery USB created for the affected device, boot the PC from that drive. Recovery from the drive reinstalls Windows and removes personal files, applications, and settings, so back up personal files before proceeding. Select Recover from a drive, choose Just remove my files or Fully clean the drive, then select Recover.
A clean installation is another fallback, including when Windows cannot start. Use Windows 10 installation media unless you intentionally plan to migrate to another version.
A clean installation can remove files, applications, settings, and manufacturer customizations, so back up personal files before starting. Create Windows 10 installation media, boot from it, choose the language, time, and keyboard preferences, then select Next and start Windows installation. Install the edition for which the PC is licensed.
Use recovery options for your Surface or Dell
For a supported Surface, open Microsoft’s Surface Recovery Image Download page and select Sign In. Follow the Microsoft account flow, identify your Surface, and have its serial number available. Download the offered image for your model, choosing the most recent appropriate image when several appear; a Windows 10 image is not guaranteed for every Surface.
Creating the Surface recovery USB erases its existing contents, so prepare a blank USB drive, normally 32 GB. Search Start for Recovery Drive, open it, and select Yes. Uncheck Back up system files to the recovery drive, select Next, select the USB drive, then select Next, Create, and Finish.
Copying the recovery files replaces matching files on the prepared USB drive. Open the downloaded recovery ZIP, copy its contents to the USB, and select Replace the files in the destination.
With your Surface off and connected to power, insert the USB, hold Volume down, and press and release Power. Release Volume down at the Surface logo, then choose your language and keyboard. This procedure applies to compatible Surface Pro, Laptop, Go, Studio, and Book devices using their model-specific image.
Surface recovery removes personal data, so back up personal files before starting the restoration. Select Recover from a drive, or select Troubleshoot > Recover from a drive if that is the path shown. Choose Just remove my files or Fully clean the drive, then select Recover.
On eligible Dell models originally supplied with Windows, BIOSConnect can download recovery tools when local recovery is unavailable. Turn on the PC, repeatedly press F12, and select BIOS Setup or System Setup. Enable BIOSConnect and SupportAssist OS Recovery, whose BIOS locations vary by model, then save and restart.
Press F12 again and select SupportAssist OS Recovery. Connect Ethernet, or select Wi-Fi, enter its password, and select Connect so BIOSConnect can download the recovery program. BIOSConnect is model dependent and is not a separate F12 menu item; use installation media if your Dell does not support it.
A factory reset erases personal files, so back them up before choosing that option. Continue with the repair or recovery workflow available in SupportAssist OS Recovery.
Resize the recovery partition only for space failures
Partition resizing applies when servicing evidence identifies insufficient recovery-partition space, including on Windows 10 22H2. Microsoft’s procedure requires the recovery partition to follow the Windows partition. If those conditions do not match your PC, continue with the applicable image-repair or installation-media route.
In an administrator Command Prompt, run reagentc /info and record the actual disk and recovery-partition numbers. Disable Windows RE before working on the partitions:
reagentc /disableSelecting the wrong partition during deletion can destroy its contents, so back up personal files before proceeding. Open DiskPart, select the correct OS disk and OS partition, and shrink the OS partition with:
shrink desired=250 minimum=250Next, select the recovery partition identified from the Windows RE information. Deleting the wrong partition is destructive, so confirm that selection before running:
delete partition overrideRecreate the recovery partition using commands for your disk’s partition style. For a GPT disk, run:
create partition primary id=de94bba4-06d1-4d40-a16a-bfd50179d6acgpt attributes=0x8000000000000001For an MBR disk, use the MBR creation command instead. Run:
create partition primary id=27Formatting erases the selected partition’s contents. With the newly created recovery partition selected, format it using:
format quick fs=ntfs label="Windows RE tools"On an MBR disk, also set the recovery partition’s ID. Run:
set id=27List the volumes, then exit DiskPart. Reenable Windows RE and check its configuration with these commands in order:
list volexitreagentc /enablereagentc /infoTest recovery and prepare for the next repair
After restoring Windows RE, test access through the normal startup controls. On Windows 10, open Settings > Update & Security > Recovery, then under Advanced startup, select Restart now. Alternatively, hold Shift while selecting Power > Restart, including from the sign-in screen.
You can also schedule a recovery boot from an administrator Command Prompt when Windows RE is usable. Run the following command, then restart the computer:
reagentc /boottoreIf your goal is to reset Windows without losing files, choosing Keep my files still removes applications and settings, while choosing Remove everything also removes personal files, so back up personal files first. On Windows 10 22H2, select Start > Settings > Update & Security > Recovery. Under Reset this PC, select Get started, then choose Keep my files or Remove everything.
Choose Cloud download or Local reinstall for the installation files. Cloud download supplies Windows installation files during reset; if the recovery-environment error continues, use the installation-media route.
Once recovery files work again, you can create a recovery USB for future use on this device. Search Start for Recovery Drive, or run recoverydrive.exe, then select Back up system files to the recovery drive and select Next.
Creating the recovery drive erases existing USB contents, so use a blank USB drive. Connect and select it, select Next, then select Create. If creation does not complete, return to image repair or installation media.
Frequently Asked Questions
Should you use reagentc /setosimage to fix this error?
No, Microsoft states that /setosimage is not used in Windows 10 or later. It belongs to an older reset-image registration workflow and should not be used for this Windows 10 repair.
Can you register a recovery image for an offline Windows installation?
Yes, the advanced reagentc /setreimage command supports an offline target through /target W:\Windows. The target and recovery-image drive letters must match the recovery session, so the example letter must be replaced with the correct one.
Does the Media Creation Tool include Windows 10 Enterprise?
No, Microsoft excludes Enterprise media from the Windows 10 Media Creation Tool. Its consumer download provides Windows 10 22H2 media in 32-bit or 64-bit versions.
Can an older recovery USB have trouble booting?
Yes, Microsoft warns that older recovery media may be affected by Secure Boot revocations. If that prevents you from using the drive, you can create Windows 10 installation media on a working PC and use the external recovery-tools route.
What other recovery entry points can you use if Windows will not start?
Windows can enter recovery automatically after startup failures; only when normal startup and restart routes are unavailable, Microsoft’s manual alternative is to interrupt startup twice by holding the power button at the logo. Start the PC a third time and select Advanced options, provided local Windows RE is usable. You can also boot an existing Windows Repair Disc CD or DVD, while manufacturer recovery buttons depend on the model.