Can you inspect the web view in an iOS app you didn't build?

Why another app's WKWebView never shows up in Safari's Develop menu, and the four things that do work: an inspectable build, an HTTPS proxy, an in-page console, and reproducing in Safari.

Cihat SALİK 4 min read

You open Safari’s Develop menu, pick your iPhone, and the app you are trying to debug isn’t there — or it is there, but only with some pages, and not the one that is broken. If the app is someone else’s, that is by design.

This guide explains why, and what you can still do. It assumes you already know the normal setup for inspecting your own app, which is on the WebView Inspector help page.

Why the app isn’t in the Develop menu

Apple’s article Enabling inspecting content in your apps is explicit about the rules:

  • WKWebView and JSContext have a property called isInspectable. It defaults to false.
  • The decision is made for each individual web view, so an app can make its in-app browser inspectable and keep everything else closed.
  • Apps linked against an SDK before iOS 16.4 and macOS 13.3 keep the old behaviour: web views were always inspectable when built for debugging from Xcode. Not when downloaded from the App Store.

Put together: a web view in an app you downloaded is inspectable only if its developers deliberately set isInspectable = true in the shipping build. Turning on Web Inspector in Safari’s advanced settings on the phone is necessary, but it can’t override the app. There is no switch, profile or developer mode that does.

Apple’s article does describe a legitimate reason to ship it on: an in-app web browser, where web authors benefit from inspecting their pages in the view’s real size and with whatever scripts the app injects. If the one you care about appears in the Develop menu under your device, you’re done — inspect it like any other page.

Option 1: Ask for an inspectable build

If you are a contractor, a QA engineer, or the team that owns the web content, this is the real fix. The app’s developers add one line behind a debug flag or internal setting:

if #available(iOS 16.4, macOS 13.3, *) {
    webView.isInspectable = true
}

and give you a development or TestFlight build. You then get the full Web Inspector — elements, console, network, storage, sources — on the exact web view that misbehaves. Every other option on this page is a workaround for not having this.

Option 2: Watch the traffic with an HTTPS proxy

You can’t see the DOM from outside the app, but you can often see what the web view loads. A debugging proxy sits between the iPhone and the network:

  • Proxyman describes itself as an HTTP debugging proxy for macOS, Windows, Linux, iOS and Android that can intercept HTTP and HTTPS requests from iOS devices. Its docs note that certificate trust and SSL proxying are still required to read HTTPS content.
  • Charles documents the iOS steps: set the proxy in the Wi-Fi settings, install its certificate from Safari, then turn on full trust under Settings → General → About → Certificate Trust Settings.

With that in place, requests from the web view appear next to everything else the phone sends: the page URL, API calls, failed scripts, redirects, response bodies. That’s frequently enough to explain a blank page or a broken login. If the app rejects the proxy’s certificate, its requests fail instead, and you have hit the limit of what can be seen from outside.

Option 3: Put a console inside your own page

The most common version of this question isn’t really about the app. It’s “my website works in Safari but breaks when someone opens the link inside a social or messaging app”. The app’s in-app browser isn’t yours, but the page is.

Load an in-page console only when you ask for it — for example when the URL has ?debug=1 — and open that link inside the app:

<script>
  if (new URLSearchParams(location.search).has('debug')) {
    var s = document.createElement('script');
    s.src = 'https://cdn.jsdelivr.net/npm/eruda';
    s.onload = function () { eruda.init(); };
    document.head.appendChild(s);
  }
</script>

Eruda and vConsole both draw a floating developer panel over the page; vConsole’s README lists logs, network requests, an element tree and storage. Neither needs a cable or a Mac, and both run wherever the page runs. Keep the trigger private and remove it after the fix. The comparison of debugging tools without a Mac goes through both in more detail.

Option 4: Reproduce outside the app — with care

Opening the same URL in Safari on the iPhone, where you can attach Web Inspector, is the quickest check. If the bug reproduces there, you have a WebKit bug and the full inspector. If it doesn’t, the difference is the app: its own user agent, its own cookie and storage rules, scripts it injects, the size of the view, or how it handles links and permissions.

That negative result is still useful. It tells you to stop looking at your CSS and start looking at what the host app does differently — and, if you build apps yourself, it is exactly the situation where a console bridge into Xcode and an inspectable debug build save hours.

What doesn’t work

Jailbreak tweaks and re-signing someone else’s app to flip the flag fall outside anything Apple supports, and outside what this guide covers. For an app you don’t own, the honest options are the four above: ask for a build, watch the network, instrument your own page, or reproduce in Safari.

Frequently asked questions

Is there a setting on the iPhone that makes every app's web view inspectable?

No. The Web Inspector switch in Safari's advanced settings allows inspection, but each app decides per web view whether it can be inspected. isInspectable defaults to false, and only the app's own code can set it to true.

Why could I inspect web views in debug builds before, but not now?

Apple changed the rule with the iOS 16.4 and macOS 13.3 SDKs. Apps linked against an older SDK keep the old behaviour, where web views were always inspectable when built for debugging from Xcode. Apps linked against a newer SDK need isInspectable set to true, even in debug builds.

My website breaks only inside a social app's in-app browser. How do I debug it?

You can't attach Web Inspector to that app, but you control the page. Load an in-page console such as vConsole or Eruda when a query parameter or test cookie is present, then open your link inside the app. You'll see the page's logs, errors and requests right on the phone.

Can an HTTPS proxy see what the web view loads?

Often, yes. A proxy such as Proxyman or Charles sees the device's HTTP and HTTPS traffic once its certificate is installed and fully trusted on the iPhone, and web view requests are part of that. If the app refuses the proxy's certificate, those requests fail instead of showing up, and there is nothing more to do from the outside.

More on the same subject.

Cihat SALİK

iOS & macOS developer, Istanbul

I write and publish every app on this site on my own, and every guide here came out of building them. Questions reach me directly.