Regular click flow
AppsFlyer relies on clicks for its attribution flow. This means that AppsFlyer must log clicks on ads to attribute an install.
When a user clicks on a banner or an ad, the following takes place:
- The user is redirected to AppsFlyer
- AppsFlyer logs the click
- AppsFlyer redirects the user to the app store
- The user installs the app
- AppsFlyer attributes the install
Sending S2S clicks to AppsFlyer
If a partner wishes to send the user directly to the store, the partner should also send a Server-to-Server (S2S) click to AppsFlyer.
Redirecting the user to the store makes for better user experience by reducing the number of redirections.
The S2S click URL is similar to the regular click URL. The only difference is that the S2S URL should include the parameter
&redirect=false. This parameter lets AppsFlyer know that this is an S2S click, and that the partner is responsible for redirecting the clicking users.
S2S clicks with referrer or device ID
Attribution of installs based on S2S clicks relies on the same matching methods explained in AppsFlyer attribution model.
The recommended and most accurate methods are Install referrer (Android only) or device ID matching. Ephemeral matching is also supported, but it's the least accurate method of attribution, and so should be used only if the two other methods are not available. See details below for each method.
In cases where a partner redirects the user to the store, the partner can append the Google Play Referrer to the link that they send to the store and also on the S2S click that they send to AppsFlyer.
This allows AppsFlyer to use the referrer as the attribution method for S2S clicks.
The ID (referrer) that the partner generates MUST be unique and should follow these guidelines:
- The prefix should be the name of the partner
- The ID must include the unique transaction ID per click
The store URL should contain the transaction ID under the referrer parameter.
The partner should append the referrer on the S2S click that it sends to AppsFlyer. The referrer is appended to the
af_ref parameter. See examples below.
The device ID can be added to the click URL in any of the following methods:
It is recommended to always send the Android advertising ID.
If you cannot send the Android advertising ID use the Android ID instead. The Android ID must be hashed using SHA1.
To support Ephemeral matching as an attribution method, AppsFlyer requires several parameters about the device. With S2S clicks, these parameters must be supplied to AppsFlyer via the click URL or the HTTP request.
For further implementation details, please contact your AppsFlyer PDM.
S2S click URL examples
The URL examples below are decoded for readability.
When you send S2S clicks, make sure the URL is encoded.
With device ID
With Google play referrer
With device ID
Timing S2S clicks
S2S click should be sent in real-time. This means that the partner sends the S2S clicks immediately after it sends the user to the relevant app store.
If the S2S click is not sent in real-time AppsFlyer might not attribute the install.
Do not accumulate S2S clicks and send them in bulk. Send the S2S clicks immediately after the user clicks an ad or a banner.
Otherwise, AppsFlyer might not attribute the install which could result in revenue loss for the partner.