Deleted Bootcamp partition space is not unavailable anymore

I uninstalled windows 10 I had installed using the bootcamp assistant, after which my MacOS disk size hasn't restored to normal. How do I reclaim the lost space? Output of the command 'diskutil list'


Solution 1:

You have a strange configuration. The drive's disk0s3 is type APFS in the GUID Partition Table (GPT), but does not appear to be APFS formatted. This would explain why the Boot Camp Assistant failed. Hopefully, these commands will fix your problem.

sudo diskutil apfs deletecontainer -force disk0s3
sudo diskutil erasevolume free none disk0s3
sudo diskutil apfs resizecontainer disk0s2 0