Developer files taking up space on Mac, folder by folder.
On a developer's Mac, the biggest folders usually aren't documents. They're build output, simulators, dependencies, and container images. Here's where each lives, how big it got on one Mac, and the safe way to reclaim it.
The short version
Five folders do most of the damage: Xcode's DerivedData, simulators in CoreSimulator, iOS DeviceSupport, every project's node_modules, and Docker's Docker.raw. The first four rebuild or download again, so they're safe to remove. Docker's file isn't: prune it with docker system prune instead. On the Mac measured here, node_modules folders alone came to about 100 GB.
How much space developer files take
Here's one developer Mac, measured in October 2026. The node_modules figure is what du counted across every project in one code folder:
| What | Default location | On one Mac |
|---|---|---|
| Xcode build data | ~/Library/Developer/Xcode/DerivedData | 1.7 GB |
| Device debug symbols | ~/Library/Developer/Xcode/iOS DeviceSupport | 4.3 GB |
| Simulators and their apps | ~/Library/Developer/CoreSimulator/Devices | 10 GB, 22 simulators |
| Simulator runtimes | Managed by macOS; xcrun simctl runtime list | 15.7 GB |
| JavaScript dependencies | node_modules in every project | About 100 GB, 266 folders |
| Docker's disk image | ~/Library/Containers/com.docker.docker/Data/vms/0/data/Docker.raw | 29 GB on disk |
That's over 160 GB, and none of it is source code. Every row can be rebuilt or downloaded again. The question is only how long you'll wait when you need it back.
Xcode: DerivedData, CoreSimulator, and DeviceSupport
- DerivedData is build products and the index, one folder per project. Quit Xcode and move the folders inside it to the Trash; the next build is slower and indexing runs again.
- CoreSimulator holds every simulator you've created, with the apps and data installed on it. Simulator runtimes, the bigger part, are managed by macOS and count toward System Data. To remove simulators whose runtime is gone, which can't run anyway:
xcrun simctl delete unavailable xcrun simctl runtime list xcrun simctl runtime delete <identifier> - iOS DeviceSupport is debug symbols copied from each iPhone or iPad OS version you've plugged in, a few gigabytes each. Delete folders for versions you no longer debug on; Xcode copies them again when that device connects.
How to clear Xcode cache covers each folder, plus archives and Swift build folders.
How to delete node_modules
Each JavaScript project installs its own copy of every dependency, so a dozen projects means a dozen node_modules folders, often hundreds of megabytes each. To list yours by size:
find ~ -name node_modules -type d -prune -exec du -sh {} + 2>/dev/null | sort -h | tail -20
Or use npkill, a small tool that finds them for you. Run it from your code folder:
cd ~/code
npx npkill
It lists every node_modules below that folder with its size. Move to one with the arrow keys and press Space to delete it. npkill deletes for good rather than moving to the Trash, so stick to projects you can reinstall. Delete node_modules in projects you haven't touched in a while; npm install brings it back from the lockfile. Package manager caches are a separate folder: see npm, Yarn, and every other tool.
Docker.raw
Docker Desktop keeps every image, container, volume, and build cache inside one file, Docker.raw. It's a sparse file, so Finder can show it at hundreds of gigabytes while du shows what it really uses: on the Mac above, Finder said 926 GB and du said 29 GB.
Never move it to the Trash: that deletes every image, container, and volume at once. Reclaim space with Docker's own command, which asks first:
docker system df
docker system prune
Docker system prune, explained covers every flag, including the one that removes volumes.
More folders that grow on their own: iCloud Drive, Dropbox, and the rest of the list. For local AI models, which can outgrow all of these, see delete local AI models.
Disk Forecast and developer files
Disk Forecast lists every folder on this page. Under Cleanup › Safe to clear: Xcode DerivedData, Xcode device support, Simulator caches, and Build folders in old projects, which is node_modules and other build folders in projects you haven't changed in 30 days. Recent projects' folders are under Worth a look, unchecked, next to the Docker disk image, which it never moves to the Trash. Its System Data window deletes simulator runtimes with xcrun simctl and prunes Docker with docker system prune -f, each after you confirm. Everything else goes to the Trash. It's free.
Questions
Is it safe to delete DerivedData?
Yes. It holds Xcode's build products and index, and Xcode rebuilds both on the next build. Quit Xcode first, then move the folders inside ~/Library/Developer/Xcode/DerivedData to the Trash.
Can I delete the CoreSimulator folder?
Not the whole folder. Delete simulators you don't use from Xcode's Devices and Simulators window, or run xcrun simctl delete unavailable. Delete runtimes with xcrun simctl runtime delete or in Xcode › Settings › Components.
Can I delete iOS DeviceSupport folders?
Yes. They're debug symbols for each device OS version you've connected. Xcode copies them again the next time a device running that version connects.
What is npkill?
A command-line tool that finds every node_modules folder below the current folder, lists them by size, and deletes the ones you pick. Run it with npx npkill. It deletes for good, not to the Trash.
Can I delete Docker.raw on a Mac?
Don't. It holds every Docker image, container, and volume. Run docker system prune to remove what nothing is using, or use Clean / Purge data in Docker Desktop to start over.
Related guides
Know before it's full.
Free. No account, no subscription.
macOS 14 or later · Apple Silicon and Intel · brew install --cask coreyhaines31/tap/diskforecast