Xcode upgrade and ~/Library/Developer/CoreSimulator [duplicate]

Yes, you can delete any simulator that you don't use. I do this routinely when I stop supporting older iOS versions.

If you delete them and then you find that you need them at some point in the future, you can redownload them from Apple's developer site.

The best way to delete them is in Xcode. Go to Window -> Devices and Simulators. This will open a new window with all the devices you use in Xcode.

At the top, tap on Simulators and you'll see a list on the left-side.

From there, find the simulator you want to delete and Cntl - click (or right-click) and select Delete.

I do this with each simulator that runs in each iOS version that I no longer support.

Update July 2020: There's a free utility in the Mac App Store named DevCleaner for Xcode. This application can display and delete simulators and various caches. I've found it be a very quick and easy way to regain space. I'm not the developer or associated with this application in any way.


Xcode now shares the simulators with all users. So, you need to remove the simulators from the following folder:

/Library/Developer/CoreSimulator/Profiles/Runtimes

For example:

cd /Library/Developer/CoreSimulator/Profiles/Runtimes
sudo rm -rf iOS\ 8.4.simruntime/
sudo rm -rf iOS\ 9.3.simruntime/

Cheers!


You can easily remove all unavailable simulators with this command in the terminal:

xcrun simctl delete unavailable

Where Xcode stores simulators in 2019+ Catalina, Xcode 11.0

Runtimes

$ open /Library/Developer/CoreSimulator/Profiles/Runtimes

For example: iOS 13.0, watchOS 6.0 These take the most space, by far. Each one can be up to ~5GB

Devices

$ open ~/Library/Developer/CoreSimulator/Devices

For example: iPhone Xr, iPhone 11 Pro Max. These are typically <15 mb each.

Explanation

Simulators are split between runtimes and devices. If you run $ xcrun simctl list you can see an overview, but if you want to find the physical location of these simulators, look in these directories I've shown.

It's totally safe to delete runtimes you don't support. You can reinstall these later if you want.


Despite @fsb's answer allows to delete simulator "instances" the right way to free a massive space used by old simulator platforms not needed anymore is going to the following folder:

~/Library/Developer/Xcode/iOS DeviceSupport

and remove the folders corresponding to the simulator/platforms you don't need anymore.

Additionally, there is a very good article including this and other tips:

  • Xcode users can free up space on your Mac
  • How to make Xcode take up less space