Skip to content
Aqib Javed.
All guides

Developer guide · Windows and Mac

What's using so much space in ~/Library on a developer Mac

By Aqib Javed · Updated Nov 2, 2026

On a developer Mac the big folders in ~/Library are usually ~/Library/Developer (Xcode DerivedData, iOS DeviceSupport, Archives and CoreSimulator), ~/Library/Android/sdk, and ~/Library/Caches (CocoaPods, Homebrew and app caches). Measure them with du -sh in Terminal. Build caches, old DeviceSupport folders, unused simulators and package caches are safe to clear; keep Archives. Stackyard, a free app, clears the Xcode, simulator and Android SDK parts.

Why System Data looks huge on a developer Mac

System Settings > General > Storage shows some developer files under Developer and counts much of the rest as System Data, and Apple doesn't document exactly where the line falls. Xcode, the simulators and the Android tools keep most of their bulk in your user Library, and simulator runtimes sit in /Library/Developer/CoreSimulator outside your home folder. Measuring the folders directly tells you far more than the Storage bar.

How to see what's using the space

Run this in Terminal. Each line lists the folders in one place with the largest last. If you see Operation not permitted, either give Terminal Full Disk Access in System Settings > Privacy & Security or ignore those lines; the developer folders usually read fine without it.

du -sh ~/Library/Developer/Xcode/* ~/Library/Developer/CoreSimulator/* 2>/dev/null | sort -h
du -sh ~/Library/Android/sdk/* 2>/dev/null | sort -h
du -sh ~/Library/Caches/* 2>/dev/null | sort -h | tail -15

What grows, and what's safe to clear

  • ~/Library/Developer/Xcode/DerivedData: Xcode's build cache. Safe to delete with Xcode closed; each project rebuilds it.
  • ~/Library/Developer/Xcode/iOS DeviceSupport: a folder per iOS version of every device you've connected. Delete versions your devices no longer run.
  • ~/Library/Developer/Xcode/Archives: keep. They hold the symbols for builds you shipped.
  • ~/Library/Developer/CoreSimulator: your simulators with their data, plus caches. Delete simulators you don't use with xcrun simctl delete, and clear CoreSimulator/Caches. Runtimes are removed in Xcode > Settings > Components.
  • ~/Library/Android/sdk: system images, NDKs, platforms and the emulator. Remove versions you don't use in Android Studio's SDK Manager or with sdkmanager --uninstall. Emulators themselves live in ~/.android/avd.
  • ~/Library/Caches: app caches, including CocoaPods and Homebrew. Clear one app's folder at a time with that app closed, or use the tool's own command below.

Gradle's cache is not in Library at all: it's in ~/.gradle. The guide to freeing up Xcode disk space on this site goes deeper on DerivedData, runtimes and simulators.

How to clear the CocoaPods cache

CocoaPods keeps every pod it downloads in ~/Library/Caches/CocoaPods, shared by all your projects. Clearing it is safe: the next pod install downloads what it needs again. A project's own Pods folder (ios/Pods in a Flutter app) is separate and comes back with pod install.

If you used CocoaPods before version 1.8, you may also have a full copy of the old master specs repo in ~/.cocoapods/repos. Since 1.8 CocoaPods uses its CDN by default, and its team says the master repo can be removed with pod repo remove master, unless your Podfile still names it as a source.

pod cache list --short    # what's cached
pod cache clean --all     # empty the cache
pod repo list
pod repo remove master

Homebrew's download cache

Homebrew keeps downloaded bottles and casks in ~/Library/Caches/Homebrew; brew --cache prints the path. brew cleanup removes old versions of installed formulae and downloads more than 120 days old, and --prune=all removes every cached download regardless of age. Add -n to see what it would remove first.

brew cleanup -n
brew cleanup --prune=all

What Stackyard covers

Stackyard is a free, open-source app for Mac and Windows. On the Mac it covers ~/Library/Developer: DerivedData, DeviceSupport, simulator caches, runtimes and simulators, with which simulators use each runtime, and it leaves Archives alone on purpose. It also lists the Android SDK's platforms, NDKs and system images, your emulators, the Gradle caches in ~/.gradle, and the Pods folders inside your projects. It doesn't scan the rest of ~/Library and doesn't clear the global CocoaPods or Homebrew caches, so use the commands above for those. Removals go to the Trash.

Questions

Is it safe to delete ~/Library/Caches on a Mac?

Mostly, because apps rebuild their caches, but clear one app's folder at a time with that app closed instead of emptying the whole folder. Apps start slower the first time while they rebuild.

How do I clear the CocoaPods cache?

Run pod cache clean --all. It empties ~/Library/Caches/CocoaPods, and the next pod install downloads the pods it needs again.

What's the difference between the CocoaPods cache and the Pods folder?

The cache in ~/Library/Caches/CocoaPods is shared by every project. The Pods folder inside a project holds that project's installed pods and is rebuilt by pod install.

Why is Mac System Data so large on a developer Mac?

Simulator runtimes, Xcode caches, the Android SDK, emulators and tool caches all add up, and much of it is counted as System Data. Measure the developer folders with du -sh before deleting anything.

Can I delete the whole ~/Library/Developer folder?

You can, but it removes Archives, your simulators and their data, and device support files along with the caches. Clear the folders inside it one at a time instead, and keep Archives.