# How to Clear macOS System Data for Developers

> On a developer Mac, bloated “System Data” in macOS Storage Settings is usually caused by hidden files inside ~/Library/Developer, ~/Library/Containers, ~/Library/Caches, and home dot-folders (~/.gradle, ~/.cargo, ~/.ollama, ~/.cache/huggingface). Clearing stale Xcode Derived Data, superseded simulator runtimes, container caches, and unused package stores safely reclaims 40–200+ GB without touching source code.

- **Canonical URL**: https://cruft.app/guides/macos-system-data-developers
- **Category**: macOS Storage
- **Typical Reclaimable Space**: 40–200+ GB
- **Last Updated**: 2026-12-04

## Quick Facts

- **Typical System Data bloat**: 80–350 GB on active dev Macs
- **Fastest safe wins**: Xcode Derived Data, Simulator Runtimes, Gradle, Homebrew, uv/pip
- **Biggest hidden files**: Docker.raw / OrbStack data.img, Ollama weights, Unreal DDC, VMs
- **Safe deletion rule**: Move to Trash first; never delete running VMs, active Xcode, or unbacked-up dSYMs

## Exact macOS Paths & Safety Reference

| Location | macOS Path | Typical Size | Safety | Rebuild / Effect |
| --- | --- | --- | --- | --- |
| Xcode Derived Data & Previews | `~/Library/Developer/Xcode/DerivedData` | 10–50 GB | Safe | Xcode rebuilds indexes and build products on next compile. |
| iOS Simulator Runtimes | `CoreSimulator runtime images (xcrun simctl runtime)` | 7–40 GB | Re-download | Re-download any OS version from Xcode › Settings › Components. |
| Docker & OrbStack Virtual Disks | `~/Library/Containers/com.docker.docker/Data/vms/0/data/Docker.raw` | 10–80 GB | Review | Resets local images, containers, and volumes — prune or back up first. |
| Local AI Models (Ollama, HF, LM Studio) | `~/.ollama/models & ~/.cache/huggingface/hub` | 10–120 GB | Re-download | Frees space immediately; re-pull models whenever needed. |
| Android Gradle & SDK Images | `~/.gradle/caches & ~/Library/Android/sdk/system-images` | 10–45 GB | Safe | Gradle rebuilds caches; unused emulator images re-download via SDK Manager. |
| Homebrew, Cargo, uv, pip & Node | `~/Library/Caches/{Homebrew,uv,pip} & ~/.cargo/registry` | 5–35 GB | Re-download | Package managers re-fetch bottles, wheels, crates, or tarballs on demand. |
| Leftovers of Uninstalled Apps | `~/Library/{Application Support,Caches,Containers,Group Containers}` | 2–25 GB | Review | Removes orphaned caches, support files, and LaunchAgents left behind after dragging apps to Trash. |

## Why macOS files developer caches under “System Data”

macOS System Settings › General › Storage only breaks out Applications, Documents, Photos, and a small Developer slice. Everything inside ~/Library/Containers (Docker Desktop, UTM), ~/Library/Caches (Homebrew, uv, pip, Playwright, CocoaPods, Xcode), /Library/Developer, and hidden home directories like ~/.gradle, ~/.cargo, ~/.ollama, and ~/.cache/huggingface falls into the grey “System Data” bucket.

Because macOS doesn't know which Xcode build belongs to a repo you deleted six months ago or which Android system image has no emulator attached, it leaves all of it alone until a macOS or Xcode update refuses to unpack.

## Step 1: Measure where the gigabytes actually sit

Before deleting anything, check the top-level developer folders from Terminal so you clean the real 20 GB culprits first instead of chasing megabytes.

**Inspect common developer storage hotspots**

```sh
du -sh ~/Library/Developer ~/Library/Caches ~/Library/Containers/com.docker.docker ~/.gradle ~/.cargo ~/.ollama ~/.cache 2>/dev/null | sort -hr
```

> Note: macOS may ask Terminal for permission to inspect protected Containers unless Terminal has Full Disk Access.

## Step 2: Clear what regenerates automatically

Start with build caches and package downloads that tools regenerate on their own. Avoid running broad rm -rf commands on folders you haven't inspected — rm -rf skips the macOS Trash permanently.

- Clear stale Xcode Derived Data for projects you haven't opened in 30+ days, plus SwiftUI preview simulators in ~/Library/Developer/Xcode/UserData/Previews.
- Run xcrun simctl delete unavailable and remove superseded simulator runtimes from older iOS point releases.
- Clear Homebrew downloads and superseded Cellar versions with brew cleanup --prune=all.
- Remove unused Playwright/Puppeteer/Cypress browser revisions in ~/Library/Caches/ms-playwright and ~/.cache/puppeteer.
- Clear wheel and crate caches in ~/Library/Caches/uv, ~/Library/Caches/pip, ~/.cargo/registry/cache, and old ~/.gradle/caches version directories.

## Step 3: Review high-impact items that may hold unique data

Some of the largest folders inside System Data cannot be blindly wiped without losing work. Always inspect these explicitly before removing them:

- Xcode Archives (~/Library/Developer/Xcode/Archives): contain dSYM files needed to symbolicate crash logs from shipped app versions.
- Docker.raw & OrbStack data.img: deleting the virtual disk wipes local database volumes and unpushed images.
- Conda environments (~/*/envs): custom data-science environments can be painful to reconstruct if no environment.yml exists.
- UTM (.utm) and Parallels (.pvm) bundles: each bundle is an entire guest operating system and its files.

## How Cruft Automates This Safely

- Scans all 39 developer locations across 6 toolchains in one offline pass and labels every item Safe, Re-download, or Review.
- Select Recommended chooses only stale, auto-regenerating or superseded items — never touching Archives, active simulators, Docker disks, Conda envs, or VMs.
- Moves files to the macOS Trash by default so you can restore anything with one drag.

Download Cruft free to scan (https://updates.cruft.app/Cruft.dmg) or buy a lifetime 3-Mac license for €15 once (https://license.cruft.app/buy).

## Frequently Asked Questions

### Why is macOS System Data over 200 GB on my MacBook?

On software development Macs, System Data accumulates hidden files inside ~/Library/Developer (Xcode Derived Data, Device Support, Simulators), ~/Library/Containers (Docker Desktop and UTM disks), ~/Library/Caches (Homebrew, uv, pip, Playwright, CocoaPods), and hidden dot-folders like ~/.gradle, ~/.cargo, and ~/.ollama.

### Is it safe to delete everything in ~/Library/Caches?

No — blindly running rm -rf ~/Library/Caches while apps are running can corrupt active state or wipe cached files apps expect while open. Clean specific toolchain caches while the corresponding IDE or daemon is closed, and prefer moving files to Trash.

### Do I need Full Disk Access to clean macOS System Data?

Not for most developer caches. Xcode Derived Data, Gradle, Cargo, Homebrew, uv, Ollama, and project build folders live in standard user paths. Full Disk Access is only needed to inspect sandboxed app containers like Docker Desktop or UTM.
