Locating Xcode 6 Simulator Documents and Apps

I’ve written twice before revealing where Xcode stores documents and applications.

With the release of Xcode 6, Apple has once again changed the location and directory hierarchy. This time around the .app file and documents managed by your app are in different folders.

This is a welcome change, as your app and data, for each device type available in the simulator, are stored separately. For example, if you run your app on an iPhone 5s simulator, the location of the .app file and the app data will be stored in a separate folder if you run your app on an iPad simulator.

So you ask, when/why do I need to know this? When your app reads/writes documents (text, plist, core data SQLite files, etc) it can very helpful to know where the files live – e.g. to create test files and view files written by your app.

Also, knowing the location of the .app file created by Xcode 6 can be helpful if you need to reference the file path. For example, I run UI Automation scripts from a command line (versus within Xcode) – one of the parameters required is the path to the .app file.

Root of All Xcode 6 Simulator Files

All Xcode 6 simulator files are stored within the directory hierarchy beginning at:

~/Library/Developer/CoreSimulator

To get there quickly, in Finder, enter Shift-Command-G and paste in the path.

Path To Xcode 6 Simulator Devices

Within the CoreSimulator folder there is a list of devices, here is the path:

~/Library/Developer/CoreSimulator/Devices/{DEVICE-ID}

Each DEVICE-ID represents a unique device available in the simulator, iPad, iPhone, iPad Retina, etc

XCode 6 simulator types

A quick way to know which folders contain your recent simulator test runs, is by the date the folders were last modified. My test app was run on an iPhone and iPad Retina, the two folders highlighted above.

Path To Simulator Apps on Xcode 6

Expanding one of the devices folders makes for an impressive directory structure:

Xcode 6 documents folders

At this point you can see the full path to the app:

~/Library/Developer/CoreSimulator/Devices/{DEVICE-ID}/data/Containers/Bundle/Application/{APPLICATION-ID}/

Here is the path to TestApp.app on my system:

~/Library/Developer/CoreSimulator/Devices/9A586EF0-D8B6-450A-A39D-E9802BE42333/Data/Containers/Bundle/Application/DCDED659-546B-4866-89CD-A0655568E419/TestApp.app

Path To Simulator Documents on Xcode 6

Documents created and managed by your app are here:

~/Library/Developer/CoreSimulator/Devices/{DEVICE-ID}/data/Containers/Data/Application/{APPLICATION-ID}/Documents/

Here’s the path to the SQLite file used in my test app:

~/Library/Developer/CoreSimulator/Devices/9A586EF0-D8B6-450A-A39D-E9802BE42333/data/Containers/Data/Application/42C6B112-32AA-4171-A894-C3B44F407062/Documents/TestApp.sql