How to inspect network traffic from iOS 15 Simulator with Proxyman

Cover Image for How to inspect network traffic from iOS 15 Simulator with Proxyman

Have you ever experienced any issues while working with API calls, when no errors being shown on Xcode, but still there's no data displayed in your app? Have you ever wanted to inspect network calls to debug your application? In this tutorial, we'll see how to use Proxyman as a man-in-the-middle proxy to capture and inspect network traffic on your iOS Simulator(s).

1. Prerequisites

2. Get started

  • This tutorial use Alamofire as an example application for debugging. You can find the source code here.

  • As soon as you download and install Proxyman successfully, network traffic would show up immediately on the Proxyman window.

Intercept network traffic on iOS Simulator

Although both Proxyman and the sample project running, we're unable to see the traffic coming at the moment. Let's install Proxyman Certificate on your Simulator!

3. Install Certificate on iOS Simulator

On the Tab bar menu, select Certificate -> Install Certificate on iOS -> Simulators.

Install Proxyman Certificate on iOS Simulator

4. Install and Trust Proxyman Certificate on iOS Simulators

Proxyman provides a Setup Guide to help you simplify all the manual work. Click Install and Trust from the setup window and it will automatically configure the Certificate for you.

Install Proxyman certificate on iOS Simulator successfully

5. Reboot iOS Simulators

Then you'll need to reboot the Simulator. Simply click Reboot ... and you're now ready to capture the network traffic from your iOS Simulator.

Install Proxyman certificate on iOS Simulator successfully

6. Inspect the network traffic

Once you install the Certificate and reboot the Simulator, you can re-run the application and make an API call. Proxyman will capture and display the content of requests/ responses for your debugging.

Inspect the network traffic coming from/to your iOS Simulator

7. SOME TIPS & NOTES

7.1 Proxyman can dectect how many Simulators are running

It's worth mentioning that Proxyman can auto-detect and let you know how many Simulators are running. Thus, if you haven't started your application or stop running it, the window would appear like this:

Proxyman auto-detect how many Simulators are running

In case you have 2 Simulators running at the same time, Proxyman can tell you also:

Proxyman auto-detect how many Simulators are running

7.2 What if I am unable to see traffic from my iOS Simulator?

In case you get any SSL errors or unable to see HTTP/HTTPs requests on iOS Simulators, check out the Troubleshooting section on Proxyman documentation to see if the issue can be resolved. If it doesn't not work also, don't hesitate to write us an email and we'd love to help you out.

8. Conclusion

While working with network calls can be tricky and frustrating sometimes, debugging them should now be a breeze for you. Proxyman, or other mitm proxy tools, can help you to capture and inspect HTTP/HTTPS traffic frrom your iOS Simulator. If you feel up for this tutorial and decide to become a netwoking wizard, check out our series about Proxyman advanced features such as Map Local, Breakpoint, or Scripting tool. They could help you modify HTTP/HTTPs requests/responses.

We hoped you enjoyed this tutorial. Happy debugging! ๐Ÿ‘จ๐Ÿปโ€๐Ÿš€

Proxyman is a high-performance macOS app, which enables developers to capture and inspect HTTP(s) traffic from apps and domains on iOS devices, iOS Simulators, and Android devices.

Get it at https://proxyman.io/

Hang Nguyen
Hang Nguyen