> ## Documentation Index
> Fetch the complete documentation index at: https://docs.median.co/llms.txt
> Use this file to discover all available pages before exploring further.

# Deep linking overview

> Set up Universal Links, App Links, and Web Credentials for your domains.

**Universal Links** (iOS) and **App Links** (Android), often grouped as **deep links**, let `http://` and `https://` URLs open in your Median app instead of the mobile browser when users tap them in email, SMS, or other apps. When configured, they provide a smoother, more native experience.

Enable Universal Links, App Links, and optional URL schemes in Median App Studio. When a user opens a matching link on a device, the configured link type determines whether the URL opens in your app instead of the mobile browser.

**Web Credentials** (iOS only) lets your app offer the passwords and passkeys that users saved for your website, so they can sign in without typing them again.

> [!TIP]
>
> **Test  with our demo page**
>
> We host a ready-made demo page at
>
> that calls the  features through the Median JavaScript Bridge.
> Load it inside your Median app during development, either by setting it
> as your app's website URL in App Studio or by navigating to it from your
> own site, and use it to confirm  works on a real device before
> you add it to your own pages.
>
> The demo page only works inside a Median app with  enabled.
> Opened in a regular mobile or desktop browser, the native features
> won't respond. Remember to switch your app back to your own URL before
> release.
>
> After setup, validate your implementation using the [Deep Linking Validator](https://docs.median.co/docs/deep-linking-validator.md).

## How deep linking works

Configure **Universal Links** (iOS) or **App Links** (Android) in Median App Studio. Once configured, links that match the domains you specify open in the app instead of the browser.

iOS and Android only trust your app with a domain after they find a file hosted on that domain, so setup has two parts: add your domains in App Studio, then host the files App Studio generates.

### Best practice

Add both your **root domain** and the **`www`** host (for example, `median.co` and `www.median.co`) so coverage matches how links are shared.

## Set up your domains

**1. Configure your domains**

In App Studio, go to **Link Handling → Universal Links / Deep Links / Web Credentials** and add each domain your links use, such as `example.com`. Enter the domain only, without `https://`, a port, or a path.

For each domain, select what it's used for. New domains start with **Universal Links** selected, and each domain needs at least one option.

| Option | Platforms | Description |
| - | - | - |
| **Universal Links** | iOS and Android | Links to this domain open in your app. |
| **Web Credentials** | iOS only | Your app offers the passwords and passkeys users saved for this domain. See [Web Credentials configuration](#web-credentials-configuration). |

For Android, set **Android link type** to **App Links** or **Web Links**. See [App Links configuration](#app-links-configuration).

**2. Host the file on your domains**

Open the **iOS** and **Android** tabs. Copy or download each file and upload it to the path App Studio shows, over HTTPS with no redirects.

* **iOS:** Upload the same `apple-app-site-association` file to every domain. Replace `<Team ID>` with your [Apple Team ID](https://developer.apple.com/help/glossary/team-id/) first.
* **Android:** With **App Links**, upload `assetlinks.json` to each domain that uses Universal Links. Your app's signing fingerprint is added to the file after your first Android build. **Web Links** need no file.

**3. Rebuild your app**

Your domains are added to your app when it's built, so rebuild after you change them. Then check your setup with the [Deep Linking Validator](https://docs.median.co/docs/deep-linking-validator.md).

> [!TIP]
>
> **Use your AI agent**
>
> Use the Median MCP with your AI agent to add domains for Universal Links and Deep Links in your app. See
> [Median MCP server](https://docs.median.co/docs/mcp-server.md) to set it up.
>
> You still host the association files on each domain, as described in the steps above.

## Platform configuration

### Android

Android uses only the domains that have **Universal Links** selected. Domains that only use Web Credentials aren't added to your Android app and don't need `assetlinks.json`.

### App Links configuration

Tapping a deep link on Android may show a **disambiguation** dialog so the user can pick your app or a browser.

You can enable **App Link verification** so matching links open **directly** in your app. Host a Digital Asset Links file on your site, typically at:

`/.well-known/assetlinks.json`

That file proves you control the domain. See [Verify Android App Links](https://developer.android.com/training/app-links/verify-site-associations).

Host `assetlinks.json` correctly **before** you publish; otherwise verification can fail. To verify the file, use Google’s [Statement List Generator and Tester](https://developers.google.com/digital-asset-links/tools/generator): enter your app package name and the **SHA-256** fingerprint referenced in `assetlinks.json`, then run **Test Statement**. Repeat for **each hostname** you add in App Studio.

#### Example: `assetlinks.json`

```json JSON theme={null}
/* Example - Android assetlinks.json */
[
  {
    "relation": ["delegate_permission/common.handle_all_urls"],
    "target": {
      "namespace": "android_app",
      "package_name": "co.median.android.padzoa",
      "sha256_cert_fingerprints": [
        "ED:30:0F:A9:AB:9D:00:34:9D:48:B0:91:69:83:D7:C9:FE:0A:95:FE:F2:E0:38:25:C9:97:37:D8:F3:16:0B:E0"
      ]
    }
  }
]
```

### iOS

### Universal Links configuration

On iOS, the user may see a confirmation step to open a Universal Link in your app. You must host an **Apple App Site Association** (AASA) file at:

`/apple-app-site-association` or `/.well-known/apple-app-site-association`

See Apple’s documentation on [Universal Links](https://developer.apple.com/library/archive/documentation/General/Conceptual/AppSearch/UniversalLinks.html) and supporting associated domains in Xcode.

Requirements:

* Create an **explicit app ID** in your Apple Developer account for your app’s bundle ID.
* In the provisioning profile for that app ID, enable **Associated Domains** under App Services. Universal Links and Web Credentials both need it.
* Include your app ID (with **TEAMID** from your Apple Developer account) in the AASA file on your domain.

#### Example: `apple-app-site-association`

```json JSON theme={null}
/* Example - /apple-app-site-association */
{
  "applinks": {
    "apps": [],
    "details": [
      {
        "appID": "TEAMID.co.median.example",
        "paths": ["*"]
      }
    ]
  }
}
```

> [!WARNING]
>
> **iOS tips**
>
> * Deep links on iOS require a path in the URL. For example, `http://example.com` will not work, but `http://example.com/PATH` will.
> * If you use multiple subdomains (`example.com`, `www.example.com`, `support.example.com`, and so on), each needs its own Associated Domains entry and its own `apple-app-site-association` file.
> * Serve the AASA file with `Content-Type: application/json`, over `https://` with a valid certificate, returning HTTP 200 with no redirects. After deployment, you can test the file with [Branch’s AASA validator](https://branch.io/resources/aasa-validator/). Additional references: [Universal Links](https://developer.apple.com/library/prerelease/ios/documentation/General/Conceptual/AppSearch/UniversalLinks.html) and [Associated Domains](https://developer.apple.com/documentation/xcode/supporting-associated-domains).

### Web Credentials configuration

Web Credentials lets iOS offer the passwords and passkeys that users saved for your website inside your app. Users sign in with AutoFill instead of typing their details, and passkeys created on your website work in your app. See Apple's [Shared web credentials](https://developer.apple.com/documentation/security/shared-web-credentials) documentation.

When a domain uses Web Credentials, the `apple-app-site-association` file App Studio generates includes a `webcredentials` block with your app ID. App Studio adds the `applinks` block only when a domain uses Universal Links, and the `webcredentials` block only when a domain uses Web Credentials.

#### Example: `apple-app-site-association` with Web Credentials

```json JSON theme={null}
/* Example - /apple-app-site-association with Web Credentials */
{
  "applinks": {
    "apps": [],
    "details": [
      {
        "appID": "TEAMID.co.median.example",
        "paths": ["*"]
      }
    ]
  },
  "webcredentials": {
    "apps": ["TEAMID.co.median.example"]
  }
}
```

## URL scheme protocol

Custom URL schemes are an **advanced** option: app-specific link formats (for example, `youruniquestring://example.com/path`) that open content in your mobile app instead of a browser. They are commonly used for **mobile authentication redirects** and advanced in-app navigation.

> [!WARNING]
>
> **Note**
>
> Custom URL schemes only work on mobile devices and are not supported in desktop browsers. Implementation is recommended for advanced developers.

### How URL schemes work on Android and iOS

Define a **unique** scheme string that does not collide with other apps. Standard web URLs use `http://` or `https://`; a custom scheme might look like:

`youruniquestring://`

Once configured, your app can recognize URLs such as:

`youruniquestring.https://example.com/path`

If the app is installed and the user taps a matching link, the system launches your app and opens the path (for example, `https://example.com/path`) inside it.

> [!WARNING]
>
> **Important**
>
> Use only lowercase letters in your custom scheme. Uppercase letters and numbers may lead to inconsistent behavior across platforms.

### Example use case

If your scheme identifier is `youruniquestring`, links such as the following can trigger deep linking:

* `youruniquestring.http://example.com/login`
* `youruniquestring.https://example.com/dashboard`

On supported mobile devices, these open the corresponding experience inside your app.

### Platform-specific implementation guides

* [Define a custom URL scheme for your iOS app (Apple Developer)](https://developer.apple.com/documentation/xcode/allowing_apps_and_websites_to_link_to_your_content/defining_a_custom_url_scheme_for_your_app)
* [Create deep links in your Android app (Android Developers)](https://developer.android.com/training/app-links/deep-linking)


## Related topics

- [Salesforce overview](https://docs.median.co/docs/salesforce.md)
- [Deep Linking Validator](https://docs.median.co/docs/deep-linking-validator.md)
- [Deep linking for Salesforce Experience Cloud](https://docs.median.co/docs/salesforce-deep-linking.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.