In-App Browsers: What They Are and Why Your Deep Links Break

An in-app browser is a webview that another app runs inside itself. On Android the default is to hand a tapped link to the app that handles it, and the app keeps you inside by choosing otherwise. Here is why the tap stays inside, and what to build that survives it.

Illustration of a phone app opening a webview inside itself instead of launching the installed app
Illustration of a phone app opening a webview inside itself instead of launching the installed app

An in-app browser is a webview that another app runs inside itself, and it is where deep links most often die. Android's documented default is to hand a tapped link to an app that handles the URL, usually the browser. An app that wants to keep you inside sets a WebViewClient, and after that every tapped link loads in its own webview. Apple documents that universal links open your app from within a WKWebView.

Apple does not document why the handoff fails inside a particular app, so treat that as a known unknown rather than a bug you can fix.

What an in-app browser actually is

Four different components get called the same thing.

WKWebView is the embedded browser most iOS apps build with. Apple describes SFSafariViewController as an object that "presents a self-contained web interface inside your app," and adds that "interactions with the web interface aren't visible to your app."

On Android, android.webkit.WebView renders inside your app with no browser controls. Google is blunt that it "doesn't include the features of a fully developed web browser, such as navigation controls or an address bar." Custom Tabs is the other: Google calls them "a feature in Android browsers that gives app developers a way to add a customized browser experience directly within their app," powered by the user's preferred browser.

Each is a component with whatever navigation logic its owner wrote around it, plus whatever it chose to let the page read.

Android: the default is to hand off

Google's WebView documentation says that "when the user taps a link from a web page in your WebView, by default, Android launches an app that handles URLs. Usually, the default web browser opens and loads the destination URL."

Untouched, the tap leaves. Whether your app is the one that opens depends on domain verification, which is a separate problem with its own fix.

The host app keeps you inside by overriding the handoff. It supplies a WebViewClient through setWebViewClient, and from then on "all links the user taps load in your WebView." A finer control is shouldOverrideUrlLoading, where the app decides URL by URL whether to hand off.

That is the in-app browser: a component configured so the tap stays inside.

iOS: what Apple documents, and what it does not

Apple's documentation states that users open your app "when they click links to your website within their browser app and WKWebView." So the platform supports the handoff from inside a webview, and the question worth asking is not whether WKWebView can do it.

When a universal link works in Safari and fails in a specific app's browser, Apple documents no cause. That is the honest position, and it is also the practical one, because the difference is in another team's code. It may be their navigation handling, an association file that fails under their User-Agent, a redirect that rewrites the link, or the same-domain rule below. We have not traced which one applies to a given app, and neither does any page we found.

TN3155 is still worth reading for the failure modes it does document, but its note that "it is up to third-party web browsers to enable universal links functionality" is about browsers as products, not about every app that embeds a webview.

Component Untouched tap What keeps it inside
Android WebView handed to the app that handles the URL the host sets a WebViewClient
iOS WKWebView universal link opens your app the host's own navigation handling
Chrome Custom Tabs behaves as a browser tap nothing, it is the browser

The same-domain rule

One documented iOS rule does cause misses, and it applies to Safari and web browsers. A universal link pointing at the domain of the page the user is already on stays in the browser, because iOS reads the tap as a wish to keep browsing, and TN3155 recommends serving the link from a different subdomain instead.

Apple does not document this rule for embedded webviews, so treat the in-app version as something to test. Where it does apply, put the landing page and the deep link on separate subdomains.

The related case that bites apps: opening your own universal link programmatically with open() will not open your app. Apple says so directly.

What you can do about it

  • Give installed users a way out. A visible "open in browser" option is honest about what happened, though the tap that follows is still a browser tap and still subject to the rule above.
  • Offer a custom scheme as a second path. On Android the docs state that custom-scheme links reach the host app's callback, so it bypasses domain verification rather than the host app. Apple documents nothing about custom schemes inside a WKWebView, so test that path on iOS.
  • Handle the user who does not have the app. Deferred deep linking resolves the destination on first open, which is the only route that survives both a failed tap and a missing install.
  • Make the loss visible. Without arrival logging you cannot tell how many taps died in someone else's browser.

We build deferred deep linking into the free tier, and link attribution logs arrivals so the drop is measurable rather than assumed.

What to check first

  1. Tap the link inside the app you actually share in, not in Safari or Chrome, and record which app it was.
  2. Confirm the domain is verified, since neither App Links nor universal links route without it: Android App Links and iOS universal links.
  3. Check whether your landing page and your deep link share a host, and split them if they do.
  4. Put a visible browser option on the landing page and a deferred path behind it.
  5. Log arrivals from known in-app browsers as their own segment.

If the link fails inside Instagram specifically, that failure has its own fixes.