When I first started developing for iOS, I spent hours staring at console logs, trying to figure out why an API call was returning a 400 Bad Request. The problem? The logs didn’t show me the actual payload being sent over the wire. That’s where learning how to use charles proxy for ios debugging changed my workflow entirely.

Charles Proxy acts as a ‘man-in-the-middle,’ allowing you to intercept every single byte of data leaving your iOS device. Whether you need to verify a header, simulate a slow 3G connection, or rewrite a server response to test an edge case, Charles is the industry standard for a reason.

Prerequisites

Before we dive into the configuration, ensure you have the following ready:

Step-by-Step Configuration

Step 1: Configure Charles on your Mac

First, we need to tell Charles to listen for connections from other devices on the network.

  1. Open Charles Proxy.
  2. Go to Proxy → Proxy Settings....
  3. Ensure the port is set to 8888 (default) and check the box Enable transparent HTTP proxying.
  4. Go to Proxy → Access Control Settings and click Add. Enter 0.0.0.0/0 to allow all devices on your local network to connect (you can restrict this to your specific IP for better security).

Step 2: Configure the iOS Device

Now we need to route the iPhone’s traffic through your Mac. As shown in the image below, you’ll find these settings in the Wi-Fi menu of your device.

  1. On your iPhone, go to Settings → Wi-Fi.
  2. Tap the (i) icon next to your connected network.
  3. Scroll down to Configure Proxy and select Manual.
  4. Server: Enter your Mac’s local IP address (found in Charles under Help → Local IP Address).
  5. Port: 8888.
  6. Tap Save.
iOS Wi-Fi proxy settings showing manual configuration with server IP and port 8888
iOS Wi-Fi proxy settings showing manual configuration with server IP and port 8888

At this point, Charles will pop up a request on your Mac asking if you want to allow the connection from the iPhone. Click Allow.

Step 3: SSL Proxying (The Critical Step)

By default, you’ll see <unknown> for HTTPS traffic. To see the actual data, you must install the Charles Root Certificate.

  1. In Charles on your Mac, go to Help → SSL Proxying → Install Charles Root Certificate on a Mobile Device → iOS.
  2. On your iPhone, open Safari and go to chls.pro/ssl.
  3. Download the profile. You will see a system alert saying “Profile Downloaded.”
  4. Go to Settings → General → VPN & Device Management, tap the Charles Proxy profile, and click Install.

Crucial Final Step: iOS requires you to manually trust the certificate. Go to Settings → General → About → Certificate Trust Settings and toggle the switch for the Charles Proxy CA certificate to ON.

Step 4: Enabling Specific Domain Interception

To avoid capturing every single background request from Apple’s system services, tell Charles exactly which domains to decrypt:

Proxy → SSL Proxying Settings... → Add → Host: api.yourdomain.com, Port: 443

Pro Tips for iOS Debugging

Once you’ve mastered the basics of how to use charles proxy for ios debugging, try these advanced techniques to speed up your development:

Troubleshooting Common Issues

If you aren’t seeing traffic, check these common pitfalls:

What’s Next?

Now that you can see your traffic, the next step is optimizing your API layer. I recommend looking into Contract Testing to ensure your frontend and backend stay in sync without needing to manually proxy every request. If you’re working in a larger team, coordinating your proxy setups can be a headache, which is why a shared licensing strategy is essential.

Ready to level up your mobile dev toolkit? Check out my other guides on automation and productivity tools to streamline your workflow.