Windows 10/11 EFI ESP partition – too many

I was using AEOMI backup to restore and it kept putting a new EFI partition on each time rather than overwriting the existing one or just keeping the existing one.

https://woshub.com/how-to-rebuild-bcd-file-in-windows-10/

Also

https://superuser.com/questions/1399789/how-do-i-find-out-which-efi-system-partition-is-in-use-by-windows-10

  • open a command prompt with admin privileges (approve UAC if demanded)
  • start diskpart -> diskpart
  • select your disk with efi partions -> sel disk 1 (if disk 1 is the correct disk)
  • list your available partitions -> list part
  • if partition 2 that is the efi partition -> sel part 2
  • detail part
    Partition 2
    Type    : c12a7328-f81f-11d2-ba4b-00a0c93ec93b
    Hidden  : Yes
    Required: No
    Attrib  : 0X8000000000000000
    Offset in Bytes: 524288000
    

Now when the Required: property is set to No, you know that is the EFI partition you can delete. The other EFI partition will have the Required: property set to Yes. Do not delete that partition.

more info about the Required property, scroll to: gpt attributes on this page.

Edit:

to change the windows boot device (efi partition) use the following command:

bcdedit /set {bootmgr} device partition=a:

*where a: is the assigned drive letter for your new efi partition

Thanks to @mbrownnyc for looking up this information bcdedit Device Setting