Deleting the EFI System Partition (ESP) and Microsoft Reserved (MSR) partition can render a Windows system unbootable. However, you can recover by booting from installation media and using command-line tools to recreate these essential structures without reinstalling the operating system.
Understanding the Critical Partitions
Before diving into the repair process, it is crucial to understand why these partitions exist. Modern Windows installations use the GUID Partition Table (GPT) rather than the older Master Boot Record (MBR). GPT relies on specific hidden partitions to function correctly. The EFI System Partition stores the bootloader files, including the firmware interface that starts the operating system. Without it, the computer cannot locate or launch Windows. The MSR partition is a small, reserved area that prevents conflicts between the data partition and the system files. If you accidentally delete these via Disk Management or third-party tools, the system loses its ability to start. This issue often arises when users attempt to resize drives or convert disk formats. For context on partition errors, see our guide on Windows 10 Partition Error Fixes.Preparation and Boot Media
To fix this disaster, you need access to the Windows Recovery Environment (WinRE). You cannot perform these repairs while booted into the broken Windows installation. Create a bootable USB drive using the Media Creation Tool from another working computer. Download the latest version of Windows 10 or 11 ISO from Microsoft’s official website. Burn this ISO to a USB flash drive with at least 8GB of storage. Once created, insert the USB into the affected machine and restart. Enter the BIOS or UEFI settings (usually by pressing F2, Del, or F12 during startup) and set the USB drive as the primary boot device. Save changes and exit. The system will load the Windows Setup screen instead of the normal desktop. From here, select your language and keyboard preferences, then click "Repair your computer" in the bottom left corner. Navigate to Troubleshoot > Advanced options > Command Prompt. This environment provides the necessary administrative privileges to rebuild the partition structure safely.Identifying the Correct Drive
Once in the Command Prompt, you must identify which physical disk contains your Windows installation. Typediskpart and press Enter to launch the DiskPart utility. Then type list disk to display all connected storage devices. Look for the disk that matches the size of your main hard drive or SSD. Note the disk number (e.g., Disk 0, Disk 1). It is vital to select the correct disk because subsequent commands will modify the partition table. Typing select disk X (replace X with your disk number) ensures you target the right hardware. Verify the selection by typing detail disk. This command shows detailed information about the selected disk, confirming its model and capacity. Be extremely cautious not to select external drives or secondary disks that do not contain the OS. Incorrect selection could lead to data loss on unrelated volumes.
Recreating the EFI Partition
The next step involves creating the missing EFI System Partition. In DiskPart, typecreate partition efi size=100. This command creates a new partition formatted for the EFI system, allocating 100 megabytes of space. Although some systems may require slightly more space, 100MB is standard for most modern Windows versions. After creation, you need to assign a drive letter temporarily so you can format it. Type select partition Y (where Y is the number of the newly created EFI partition, visible in the list). Then type assign letter=S to assign the letter S. Now, format the partition with the FAT32 file system, which is required for EFI compatibility. Type format fs=fat32 quick. Once formatting completes, remove the temporary drive letter by typing remove letter=S. This keeps the partition hidden from the operating system but accessible to the firmware.
Recreating the MSR Partition
With the EFI partition established, create the Microsoft Reserved partition. Typecreate partition msr size=16. This allocates 16 megabytes for the reserved area, preventing future allocation conflicts. Unlike the EFI partition, the MSR partition does not need a drive letter or formatting. It is automatically recognized by Windows as a reserved system area. You can verify both partitions now exist by typing list partition. You should see two small partitions at the beginning of the disk: one marked as "System" (EFI) and one as "Reserved" (MSR). If they appear correctly, you can exit DiskPart by typing exit.
Restoring Boot Files
The final technical step is ensuring the boot files are correctly placed. While DiskPart creates the structure, it does not copy the bootloader files if they were deleted. Use thebcdboot command to restore them. Assuming your Windows installation resides on the C: drive (which may be labeled differently in WinRE), type bcdboot C:\Windows /s S: /f ALL. Replace C: with the actual drive letter of your Windows folder if different. The /s S: flag points to the EFI partition we just created. The /f ALL flag ensures both UEFI and legacy boot files are written. If the command succeeds, you will see a message stating that the boot files were successfully created. Exit the Command Prompt and remove the USB drive. Restart the computer. It should now boot normally into Windows.
Verification and Cleanup
After rebooting, open Disk Management to confirm the partitions are intact. Ensure no other operating systems have been corrupted. Run a quick system check usingsfc /scannow in an elevated Command Prompt to ensure system integrity. If you encounter issues related to partition conversion or splitting, refer to resources on GPTMBR Conversion Issues. Regular backups of your system image are recommended to prevent such disasters in the future.