A deferred deep link sends a user to a place in your app after routing them via the App Store to install the app first.
How it works
This is how a deferred deep link works:
- The user clicks on an Adjust deep link.
- Adjust’s servers redirect the user to the App Store.
- The user installs your app and opens it.
- Adjust’s servers perform attribution and send the deep link to the Adjust SDK.
- Your app displays its preliminary content, such as onboarding screens and user login, if applicable.
- Your app retrieves the deep link from the Adjust SDK and handles the deep link.
Setup
There are 2 approaches to set up deferred deep linking in your app:
- Adjust’s servers automatically pass the deferred deep link to the Adjust SDK. When the user opens your app, the Adjust SDK automatically calls the
open(_:options:completionHandler:)
method with the deep link. If your app doesn’t have preliminary content (for example: onboarding screens and user login), or if your app already handles this content before opening the deep link, then no further configuration is required, and you can skip the rest of this section. - If your app has preliminary content (for example: onboarding screens and user login), but your app doesn’t already handle this before handling the deep link, then you can add a deferred deep link listener.
Set up a deferred deep link listener
- Set up a delegate callback for deferred deep linking. If you have already configured attribution callbacks, you can skip this step.
- If you haven’t already done so, create an instance of the
ADJConfig
class and set a delegate on theADJConfig
object in your app delegate. You need to set the delegate inADJConfig
before initializing the SDK.
- Add the
adjustDeeplinkResponse
deferred deep link callback method to the delegate. The Adjust SDK calls this method after receiving a deferred deep link.- Set your deep link handling code.
- Set the return value of the
adjustDeeplinkResponse
method to true or false. This indicates whether you want the Adjust SDK to call theopen(_:options:completionHandler:)
method to open the deep link after your deep link handling code runs.
Set up Adjust LinkMe
Adjust’s LinkMe solution is an optional feature that ensures robust deferred deep linking performance by enabling your app to read deep link information from the device pasteboard.
When a user clicks on a LinkMe URL they have the option to copy the link information to their system pasteboard. You can use the Adjust SDK to read the system pasteboard for deep link information. If deep link information is present, the Adjust SDK forwards the user to the correct page in your app.
To enable pasteboard checking in your app, pass a true
value to the setLinkMeEnabled
method on your ADJConfig
object: