Skip to main content
To attribute installs and open your app from DeepLink links on Android, you need App Links (for opening the app) and Install Referrer (for attributing the install).

1. Install Referrer (for install attribution)

Add the Play Install Referrer dependency in android/app/build.gradle:
dependencies {
    implementation 'com.android.installreferrer:installreferrer:2.2'
}
The DeepLink SDK uses this to read the referrer when the user installed the app from a link (e.g. from your DeepLink domain). So that https://your-subdomain.deeplink-domain.com/your-path opens your app:
  1. Intent filters — In android/app/src/main/AndroidManifest.xml, add an intent filter for your DeepLink host and path. Replace the host with the subdomain you use in the DeepLink dashboard (e.g. your app’s subdomain).
<activity android:name=".MainActivity">
  <!-- ... existing config ... -->
  <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="your-subdomain.deeplink-domain.com"
      android:pathPrefix="/"
      android:pathPattern="/.*" />
  </intent-filter>
</activity>
  1. Digital Asset Links — Host a /.well-known/assetlinks.json file on https://your-subdomain.deeplink-domain.com that includes your app’s package name and SHA-256 fingerprint. DeepLink may provide this or you configure it on your domain. This is required for android:autoVerify="true" to work.

3. ProGuard / R8 (if you use shrinking)

If you enable code shrinking, keep the Install Referrer and any DeepLink SDK classes from being stripped. For example:
-keep class com.android.installreferrer.** { *; }
# Add any rules provided by the invyto_deeplink package.
Check the invyto_deeplink package docs or example for the exact rules.

4. Initialize the SDK

In your Flutter app, call the SDK init with your DeepLink API base URL (see Quickstart). The SDK will use the install referrer on first launch and report the install to the Track Install API.

Troubleshooting

  • App doesn’t open from link — Confirm the host in the intent filter matches the link domain, and that assetlinks.json is reachable and correct.
  • Install not attributed — Ensure the Install Referrer dependency is added and the user actually installed from a link that points to your DeepLink domain (and that the referrer is set by the store/link).

iOS setup

Configure Associated Domains for iOS.