"Not enough free space" when trying to install XCode even though there's ~7x more free space than required

The title says it all...

I am trying to install XCode, constantly getting that message, no matter what I try. Currently I have 41+ GB free space, XCode requires 6.1 according to App Store.


Please suggest how to solve this issue.


Thanks a lot in advance!

Post not yet marked as solved Up vote post of errata Down vote post of errata
187k views
  • Me also getting same problem whenever I try to update Xcode. At least it should show update size of any app. It doesn't show update size for any app in App Store. How can we know which update is consuming how much data? If it explicitly asks that I want exactly this much of space for installing updates then we can do something about it. Without showing update size it simply goes on asking for more space for whatever free space we provide. Anyway this problem was encountered when I updated from

    Catalina 11.15 to Big Sur 11.0 (trouble moving Xcode from 12.4 (12D4e)) to 12.5

Add a Comment

Replies

I try to clean all XCode caches by this app.
https://apps.apple.com/us/app/devcleaner-for-xcode/id1388020431?mt=12

And it work.
Thank for Konrad Kolakowski
Same problem here! I've got a Mac Mini 2018 with 128gb, which had 17gb left but it still gave me that error message. I only use it for Xcode, so there isn't any random data, apart from a couple of images, which include a single wallpaper and small-ish test files.
I deleted a bunch of pre-installed apps(like Garage Band and iMovie - these were at least 5gb) and also a lot of simulators (no idea why they even existed) and two old iOS versions.
Now there are 40gb left but it still displays the same message!
I even installed DaisyDisk but there's nothing more I can delete without deleting Xcode itself! The download for Xcode 12.4 is only 11.6gb! This is ridiculous!
Update:
Yesterday I also downloaded the "Big Sur" update, which was about 13gb but apparently "only" uses 12gb according to "applications". After the download was done the app store let me start the Xcode update just fine (had to pause it, so not installed yet).

But now the OS update complains that it needs more space! I emptied the trash cash (mostly small files) and now there are almost 32gb left but it's still complaining! There isn't anything else that I can delete! I've also got a Win 10 PC with a 128gb SSD and there's a ton more data/apps on it but I've never had a problem like this with it, not even while updating from Win 7 to Win 10! *** is going on with these updates?!
Never mind, now all of sudden both updates complain and it won't let me start either of them!!! I even cleaned the damn Firefox cache to free some space!
I had the same problem. After downloading Xcode_12.5_beta_3.xip , I was not able to open it due to not enough space although I had ~30 GB but it turns out it requires +40 GB free space.
Once you have 40 gig plus space Xcode will install
Hey!

I have been facing the same problem on my 2017 MacBook Air with 8GB of RAM and 128GB of storage. I have 38GB of storage whereas Xcode only requires 11GB. What I did was I went to the developer website and downloaded the zip file from there. Now, it works perfectly! Here's the link: https://developer.apple.com/download/more/


solved it by removing xcode projects cache and build indexes from Storage Management -> Developer.

Simial problem with my Mac book air 2014 with 30 GB free. Find some cache for old devices in xCode and delete them. Now + 10GB and update is going. alternativly use app by Kolakowski. It does the same job. https://apps.apple.com/us/app/devcleaner-for-xcode/id1388020431?mt=12

Very sad to see that 40GB needed to install 5GB.

I am at MacOS 11.6 and trying to install XCode 13 that says its size on disk is 11GB only but I had to clean more than 45GB on disk to get it to start installing. 46GB worked for me.

I had this same problem. Apparently I had time machine partitioning my drives without really knowing. I am a total noob when it comes to macs as this is my first mac book. Anyway, the file system is VERY different than windows and I had no idea that I really only had 25GB of free space left and was only really using 60 GB.. the rest was all time machine back ups. This was what was preventing me from downloading xcode. I saw a few of the comments here and downloaded daisy chain. You will have to pay for the licensed version, to do what you need to. So, I tried daisy chain and it is so easy to use and not only is my mac much faster but I am also after 3 days of trying to download xcode. Just make sure that when you go into daisy chain you click on the purple areas and that will lead you to the time machine back ups that you need to remove.

I also tried this command and it work beautifully.

tmutil thinlocalsnapshots / 21474836480 4

My Environment: Macbook Air-Big Sur(11.6)

Problem #1: I have 32 GB available on my Mac, but still, I couldn't install XCode 12.5.1 because of no space.

Solution: Got an External Hard Disk from my Friend(Support only NTFS-Windows file format), copied the .xip (11GB) file and tried to extract it.

Problem #2: Since the external hard disk support only NTFS format I couldn't paste or extract the file in it. Solution: Installed (https://www.paragon-software.com/home/ntfs-mac/) NTFS for MAC and after successfully installing & Restart I can able to copy and extract the file.

After a couple of attempts, I can successfully extract and copy the Xcode to my MAC and it's working fine.

For Xcode 13.2.1 even 40GB was not enough. At 46GB (remember to purge purgeable storage space) it finally installed it from App Store.

What worked for me was putting a file in the trash and then emptying it. Seemed like some uninstalled programs were still lurking around behind the scenes.