OneLink templates

At a glance: Create a template to form the basis of the redirection logic for all OneLink links that you create for your various marketing campaigns. A template is required for creating links and end-user experiences.

OneLink templates

A OneLink template:

  • Is not a clickable link for your end-users; it is the foundation for generating many custom links. Usually, you only need one template per app (outside of testing) to generate as many links as you want for all your different advertising campaigns. 
  • Is where you record your decisions on how to redirect users based on their device platform and on whether or not they have your app installed.
  • Represents the routing logic at the core of all the OneLink links you create for your various marketing campaigns. This includes the redirection settings for:
    • New users without your app installed: To the correct app store or web URL
    • Existing users with your app already installed: Opening the app via Android App Links, iOS Universal Links, or URI schemes. This involves some developer work to set up.
    • Note: Redirection settings for website or app store can be overridden on the link level.

How to create OneLink templates

Who's involved

  • Only a marketer is required to set up redirection logic for new users who don't have your app installed (for example, to the correct app store or web page).
  • To add redirection logic for existing app users who already have your app installed (for example, to open the app), both a marketer and Android/iOS developers are required.


Time required

Approximately 1.5 hours, working together with your Android/iOS developers.


  • A template from which you can create links that send users to the correct app store, web page, or into the app based on their device.

Create a OneLink template with redirection logic for new app users

To create a OneLink template:

  1. In AppsFlyer, from the side menu, select Engage > OneLink management.
    The OneLink suite is an account-level feature, which lets you create OneLink templates and their custom links for all your apps.

    Note: If you don't have any templates created, an onboarding wizard opens. Follow the directions in the wizard and disregard the rest of this procedure. 
  2. Click the menu icon > Add OneLink template.
    The OneLink template setup page opens.


  3. In the OneLink template name field, enter a name.


    • A good OneLink template name includes the name of the app (for example feed_me) or the use case or experience represented by the OneLink (for example pre_launch_landing_page).
    • The name should not include the campaign or channel name or media source (since this isn't the actual end-user link, just the underlying template to create many links), or the name of the platform (Android, iOS, since multiple platforms are usually the reason for using a OneLink template in the first place).
    • This template name is only used internally. It doesn't affect your marketing attribution data and is not seen by users.
  4. In the Subdomain field, enter your subdomain name.
    • Choose a subdomain that matches your brand. For example, if your website is choose abcd as your subdomain.
    • Users will see this subdomain as part of the link URL. For example:
    • The subdomain can’t be changed once custom links are created based on this template.
    • Only use lower-case letters, digits, or hyphen (-).
    • OneLink also supports fully branded domains, that can help you improve campaign performance and increase brand exposure. Learn more
  5. Select your Android app, iOS app, or both.

  6. Set where to redirect users When app isn't installed.

    • If you've selected an Android app and an iOS app, the template is by default configured to send new app users to the correct app store.
    • If you've selected only one app, Android or iOS, the template is configured to send ALL users (iOS and Android, new and existing) to the single defined destination.
    • If you select an Android app that isn't in Google Play, you must enter a URL to which Android users are redirected.
    • [Optional] Redirect to third-party app stores if the app is in other stores besides Google Play. Make sure the app in the other stores has the same package name as the Android app selected in your OneLink template.
    • [Optional] Change to a different URL: In some cases, you may prefer to take new users to a mobile web experience instead of directly to the app store (or your app may not be listed in the store). To implement, enter that URL in the URL field. Note: If you set both a third-party redirection and a different URL, the default redirection is to the third-party app store.
    • [Optional] Turn on Display App Clip for users with Private Relay (available on iOS 14+). Learn more about App Clips.
  7. Skip When app is installed. This is discussed in the next procedure.
  8. [Optional] Change destination for When link is clicked on desktop.
    • In some cases, your link might be clicked on a desktop computer, especially if it is sent via email or social media. If you expect a lot of desktop traffic to your link, you might want to send those users to a landing page or the main website homepage, or a page where they can request an SMS link on their phone, instead of the correct app store.
    • By default, desktop users are redirected to your app's iOS App Store page, or to Google Play's app page, If an iOS app isn't defined.
  9. [Optional] Select apps from other platforms
    If you have a dedicated app version for the following:
    • Windows phone: Turn on the toggle and select app or Change to a different URL.
    • iPad: Turn on the toggle and select iPad app
    • Amazon Kindle Fire: Turn on the toggle and add the Amazon store ASIN or app page URL.
  10. Click Save OneLink template (Update OneLink template for edited templates). 
    Your OneLink template is now created and can be used to create many different clickable links (see OneLink links and experiences).

Add redirection logic for existing app users

Existing app users usually expect to be redirected directly into the app, not to an app store or web page. There are three technologies available to open the app directly after a click:

  • iOS Universal Links: Works with iOS 9 and up, and provides a smooth, secure experience when opening your app. 
  • Android App Links: Works with Android 6 and up, and provides a smooth, secure experience when opening your app. Note: Samsung OS can't open apps using Android App Links.
  • URI scheme:
    • Fallback method:
      • Android: URI scheme is an effective fallback method for when Android App Links fail to open the app either because they don't work or aren't set up
      • iOS: Limited fallback capabilities for when Universal Links fail to open the app either because they don't work or aren't set up. Learn more
    • Primary method for opening apps on Samsung devices.
    • Is an address, that when accessed, opens your app if it's installed. They are similar to website links, but open apps instead of websites.
    • Must be the same for iOS and Android. 

For the best user experience, security, and device coverage, we recommend enabling as many technologies as possible. If you enable all link technologies, OneLink will automatically apply the best method for each user. 

To add redirection logic for existing app users to your OneLink template:

  1. In AppsFlyer, from the side menu, select Engage > OneLink management.
  2. Select the OneLink template you want to edit.
  3. Click the menu icon (), then click Edit OneLink template.
  4. Scroll down to When app is installed.

  5. Follow the instructions for iOS, Android, and fallback setup:
    iOS Universal Links Android App Links URI scheme

    Universal Links take the format of regular web links (e.g. or and thus require setting a subdomain (covered in the previous guide). OneLink also supports fully branded domains, but that isn't necessary to complete this guide.

    To launch the app using Universal Links:

    1. Contact your iOS developer:
      • Give them the subdomain for this OneLink template.
      • Tell them to follow these instructions.
      • The developer returns to you with the Team ID (also called Apple App ID Prefix, for example, PF23MIWNTW).
      • If the app is not yet published, the developer must also give you the Bundle Identifier (for example, com.myapp.something).

    2. In the OneLink template page click Change to launch the app using Universal Links.
    3. In the new window, select Launch the app using Universal Links.
    4. In the Team ID field, enter the team ID provided by the developer.
    5. If the app is not published, also enter the Bundle Identifier.
    6. Click Save changes.
  6. Click Update OneLink template.


  • When you save or update your OneLink template, AppsFlyer automatically generates the AASA and/or Digital Asset Links JSON file to verify your app domain, and hosts it for you. This is critical for your Universal Links and App Links to work properly. 
  • It can take up to 1 hour for OneLink template updates to take effect.

Customize QR codes


You can customize the QR codes generated via OneLink by:

  • Adding your logo to the QR code
  • Changing the color of the QR code. 

Note: QR code customization occurs at the template level; not at the individual link level. Therefore, customizations affect all QR codes based on the edited template.

To customize your QR code:

  1. In AppsFlyer, from the side menu, select Engage > OneLink Custom Links.
  2. Hover over the Actions icon of the template you want to edit and click Customize QR code.
    The QR code editor opens.
  3. Enter the URL where your logo is hosted. For example:

    Logo requirements:

    • PNG or JPG format
    • Square or circular with a transparent background
    • Minimum dimensions 400 x 400 px
    • For printing, use maximum image resolution
  4. Set the QR code color. 
  5. Click Save.

Traits and limitations

Trait Remarks
  • Agencies are not able to create OneLink templates on their own.
  • Agencies can use existing OneLink templates to create custom attribution links for themselves if the agency is a partner of all the apps in the template.
Add/edit OneLink templates Account users require permission to add and edit OneLink templates.
OneLink templates Up to 600 OneLink templates per account.
Desktop When you set the OneLink URL or template to redirect desktop users to a different URL, the web URL is added to the link in the af_web_dp parameter. When the link contains af_web_dp, AppsFlyer does not register a click when it comes from a desktop.
Redirect to third-party app stores

Multiple app stores can be set on the OneLink template only if the app package name is the same for all app stores. To learn more about OneLink redirection to third-party Android app stores see here.


  • Huawei and other 3rd party stores sometimes require different package names. When this is the case the same OneLink template can't be used for multiple app stores.
  • If the package name is the same, but the channel is different, the redirection works, but attribution doesn't.
  • Learn more about third-party app store attribution and data.
Updating a template

Changes to the configuration of a OneLink template take up to 1 hour to apply.

URI scheme

See here.

Got a question about OneLink templates? Check out our FAQ!

Next step

Follow the instructions to create OneLink links based on your template.