Generate HAR Files and Debug Data from Mobile Devices

HAR (HTTP Archive) files are used to capture and analyze network traffic. They are essential for debugging issues on mobile devices. Follow these steps to generate HAR files on iOS and Android devices.

Debugging mobile devices can be challenging. If you encounter an issue, you can capture data using these methods.

How to Generate a HAR Capture on iOS Devices

  1. Enable Web Inspector

    • On your iOS device, go to Settings > Safari > Advanced.
    • Enable Web Inspector.
  2. Connect to Mac

    • Connect your iOS device to your Mac using a cable.
    • Ensure your iOS device is recognized by the Mac.
  3. Reproduce the Issue

    • On your iOS device, open Safari and reproduce the issue.
  4. Open Developer Tools

    • On your Mac, open Safari.
    • Go to Develop > [Your Device] > [Your Session] to open the developer tools.
  5. Export HAR File

    • From the developer tools, export the HAR file.
    • Use Google Inspector to review the HAR file.

How to generate a HAR capture on Android devices

Android's process is a bit more in-depth but easier to follow once set up. They have a doc for this here: https://developer.chrome.com/docs/devtools/remote-debugging/