Tips to Clean the Xcode Cache and Stop Crashes

Xcode is a popular Integrated Development Environment (IDE) for macOS. It is meant to provide software developers with access to all the tools they need to enhance their job and performance. However, as you build and test software using Xcode, the cache of the software may quickly fill up with old and unnecessary files. Some software projects can use a lot of disk space, so it is not uncommon for developers to eventually run out of disk space.

If you are an Xcode users, you may want to consider regularly cleaning the Xcode cache. This will not only reduce disk space usage but can help prevent Xcode crashes as well. Keep in mind that when we get to the part where we delete the Xcode cached folders and files, you will need to quit the app first. But before this:

Clean your Xcode Build

An improper configuration of your current Xcode build may result in crashes and instability. To clean your Xcode build, you should do this:

  1. Open your project and head to the top menu bar.
  2. Select Product -> Clean.

You can also clean out the builder by:

  1. Open the project, and head to the Product menu you used earlier. Hold down the Option key while hovering it to uncover advanced options.
  2. Select Clean Build Folder.

Reset Content and Settings

Xcode uses a simulator to run certain apps and scripts. If it has been clogged because of poorly written code, then it might lead to Xcode crashes and instability. Go to the Simulator menu and select Reset Content and Settings. Keep in mind that you will need to re-apply any configuration changes you had previously made.

Clean Xcode Derived Data

The Derived Data directory is where Xcode stores all sorts of build info and project indexes. Make sure to back up all your projects before cleaning out this folder.

  1. Open Xcode and go to Window -> Organizer.
  2. Go to Projects and select the project you are working on.
  3. You should see a new window with the Derived Data folder inside. Click the Delete button next to it.

After this, open Finder -> Go -> Go to Folder. Enter ~/Library/Developer/Xcode/DerivedData/ModuleCache and move the files inside the trash bin. Make sure to empty it after this.

September 16, 2021
Loading...

Cyclonis Backup Details & Terms

The Free Basic Cyclonis Backup plan gives you 2 GB of cloud storage space with full functionality! No credit card required. Need more storage space? Purchase a larger Cyclonis Backup plan today! To learn more about our policies and pricing, see Terms of Service, Privacy Policy, Discount Terms and Purchase Page. If you wish to uninstall the app, please visit the Uninstallation Instructions page.

Cyclonis Password Manager Details & Terms

FREE Trial: 30-Day One-Time Offer! No credit card required for Free Trial. Full functionality for the length of the Free Trial. (Full functionality after Free Trial requires subscription purchase.) To learn more about our policies and pricing, see EULA, Privacy Policy, Discount Terms and Purchase Page. If you wish to uninstall the app, please visit the Uninstallation Instructions page.