# Is it safe to delete Xcode DerivedData on Mac?

- URL: https://moreroom.app/folders/xcode-deriveddata
- Item: Xcode build data (DerivedData)
- Location: `~/Library/Developer/Xcode/DerivedData` (items inside)
- Verdict: Safe to remove — Rebuilt or re-downloaded automatically when needed.
- Comes back on its own: yes
- Typical size: 1–50 GB
- Source: MoreRoom rules catalogue (2026-10-17), by Yando Pte. Ltd.

## What is it?

DerivedData is where Xcode keeps everything it produces while building: compiled object files, module caches, indexes for code completion and search, build logs and test results. Each project gets its own subfolder named after the project plus a random suffix, and folders for projects you deleted long ago are never cleaned up. On an active developer Mac it typically ranges from a few gigabytes to several tens of gigabytes.

## What happens if you delete it?

Xcode recreates the folder the next time you open or build a project. The first build afterwards is a full, slower build and indexing restarts in the background; no source code or settings are lost.

## How to remove it properly

Quit Xcode, then move `~/Library/Developer/Xcode/DerivedData` (or only the subfolders of projects you no longer work on) to the Trash using Finder’s Go › Go to Folder…. Xcode › Settings › Locations shows the current DerivedData location and has an arrow button that opens it in Finder.

## Before you delete it

Avoid deleting it in the middle of a build or test run, and expect the next build to take longer on large projects.
