View crash or energy logs on devices

In the Devices and Simulators window, you can view the crash or energy logs to help diagnose a problem with your app. You can view a crash or energy log on a device where it occurred or view logs you import from other sources—for example, view logs about crashes on user devices.

If you have an archive containing the matching build and dSYM files, Xcode automatically symbolicates the logs. Xcode replaces the memory addresses in the log with human-readable function names and line numbers. Then you can view the stack traces in the Devices and Simulators window.

For this reason, do not delete archives that you upload, export, and distribute to users. For example, if you distribute your app to registered devices or distribute your app to registered computers (macOS), retain the archive so you can import unsymbolicated crash logs you receive from users.

If you include bitcode when you upload your app to App Store Connect, the App Store generates the dSYM files and you must download the dSYM files before you can view logs in the Devices and Simulators window.

View a crash or energy log on a device

  1. For iOS and tvOS apps, connect a device to your Mac. For watchOS apps, connect an iPhone paired with an Apple Watch.

  2. Open the Devices and Simulators window, then click Devices.

  3. In the left column, select the device, then select View Device Logs.

    A sheet displays the logs.

  4. In the left column of the sheet that appears, select the log you want to view.

    The log content displays on the right.

  5. Click Done.

View logs you import from other sources

  1. Open the Devices and Simulators window, then click Devices.

  2. In the left column, select the device, then select View Device Logs.

  3. Drag the log from the Finder to the left column of the sheet that appears.

  4. In the left column, select the log.

    The log appears in the detail view on the right.

  5. Click Done.

See alsoFind device crash and energy logs on a Mac or Windows computerAbout Crashes organizerAbout Energy organizer