urltoapp.dev
Learn

Deep links: open your URL app from any link

Someone taps a link to your product in WhatsApp. With App Links it opens in your app, on that product. Without them, it opens in Chrome and your app might as well not exist.

Updated Oct 20262 min readurltoapp.dev

Short answer

To open your URL app from web links, the app declares an intent filter for your domain with autoVerify="true", and your site publishes /.well-known/assetlinks.json listing the app's package name and SHA-256 signing-certificate fingerprint. Android checks the file when the app installs; if it matches, links to your domain open directly in the app at the right page.

  • Deep link: any link that opens a specific screen in an app. Plain deep links show a “Open with…” chooser.
  • Android App Link: a verified https deep link. Because you've proven you own the domain, Android opens your app directly with no chooser.

For a URL app, the “specific screen” is easy: the app just loads the tapped URL in its WebView.

Step 1: the intent filter in the app

<intent-filter android:autoVerify="true">
  <action android:name="android.intent.action.VIEW" />
  <category android:name="android.intent.category.DEFAULT" />
  <category android:name="android.intent.category.BROWSABLE" />
  <data android:scheme="https" android:host="example.com" />
  <data android:scheme="https" android:host="www.example.com" />
</intent-filter>

List every host you want to capture. Add android:pathPrefix if only part of the site should open the app (for example /product/).

[{
  "relation": ["delegate_permission/common.handle_all_urls"],
  "target": {
    "namespace": "android_app",
    "package_name": "com.example.app",
    "sha256_cert_fingerprints": ["AB:CD:...:EF"]
  }
}]

Serve it at https://example.com/.well-known/assetlinks.json with content type application/json, no redirects, on every host in the intent filter. The App Links builder writes both files from your URL.

The fingerprint trap

If you publish on Google Play with Play App Signing, users get APKs signed by Google's app signing key, not the key you uploaded with. Copy the SHA-256 from Play Console → Setup → App signing. To make your own sideloaded test builds verify too, list both fingerprints in the array.

Testing verification

  • Install the app, then on a computer run adb shell pm get-app-links com.example.app — each domain should say verified.
  • On the phone: Settings → Apps → your app → Open by default → the domain should be listed as verified.
  • Send yourself a link in a messaging app and tap it. Links typed into Chrome's address bar don't trigger App Links; links tapped elsewhere do.

Use it for login callbacks

App Links are also how a sign-in finished in a Custom Tab comes back to your app — see Google sign-in in URL apps.

FAQ

Why does my link still open in Chrome?

Usually the fingerprint in assetlinks.json doesn't match the installed app's signature, the file redirects, or a host in the intent filter has no file. Check with pm get-app-links.

Do I need App Links for a URL app?

No, the app works without them. They matter when you share links to your site and want app users to land in the app.

Can I use App Links with a site I don't own?

No. Verification requires publishing a file on the domain.

Read next