In this step by step tutorial, learn how to setup your iOS device to use Fiddler as a proxy and capture web traffic from your phone.
Last week we learned how to capture the traffic from you Android device with Fiddler. Now, let’s see how it’s done on iOS.
Want to learn more about using Fiddler to debug iOS apps? Check out our webinar on mobile app debugging with Fiddler!
First you have to have Fiddler installed on your desktop machine. The PC and the iOS device should be discoverable on the same network. This was the tricky part for me, as even when I have them on the same network, they couldn’t communicate with each other. I had to use the mobile hotspot on my machine to make them discoverable.
Just ping the device IP from your machine to be sure they can communicate.
Setting up Fiddler
First, you should enable the Allow remote computers to connect setting in Fiddler
- Open Fiddler and select Tools -> Options
- Choose the Connections tab
- Select the Allow remote computers to connect checkbox to enable the setting.
- Restart Fiddler in order the changes to take effect.
Fiddler is now listening on port 8888 (this is the default port, you can change it from the setting above).
Setting up the iOS Device
Once Fiddler is listening, we should use it as a proxy in iOS.
- Open Settings -> WiFi
- Find your current network and click the i icon
- Scroll to bottom and choose Manual on the HTTP Proxy choice
- Type your IP address in the Server field
- Type the Fiddler listening port (8888 by default) in the Port field
Your device’s traffic should be visible in Fiddler.
Capture HTTPS Traffic
With the current setup you should be able to capture HTTP traffic. However, if you try to open any HTTPS website, you’ll get the This site’s security certificate is not trusted! error. To fix this, you should trust the Fiddler root certificate.
- In your browser, navigate to http://ipv4.fiddler:8888
- Click on the Fiddler root certificate link to download it
- Install the certificate on your device.
- (iOS 10.3+) Go to General->About->Certificate Trust Settings and enable full trust for the DO_NOT_TRUST_FiddlerRoot certificate.
Now you should be able to capture HTTPS traffic too.
Once you’re done debugging, don’t forget to remove the WiFi proxy from your device.
This is all you need to know about capturing web traffic from iOS devices. If you have any questions or problems, just leave a comment below.
We always love hearing feedback, so feel free to share your thoughts on what you'd like to see with us over on our Feedback Portal. And if you're new to Fiddler, you can get started today - download Fiddler for free right here.