Learn how to enable the new Singular Links for your iOS and Android apps, including deep linking. After you've set up these prerequisites, you will be able to implement deep linking in your Singular SDK integration.
For more information, see the Singular Links FAQ and the Deep Linking FAQ.
iOS Prerequisites
Singular uses iOS Universal Links and app schemes to deep link on iOS. To enable your app to use iOS Universal Links and app scheme deep linking with Singular Links, follow these steps.
- Configure at least one sub-domain for your links in the Link Management page in Singular. For more information, see the Singular Links FAQ.
- To set up Universal Links (deep linking in iOS):
- Log into the Apple Developer Portal.
-
Go to Identifiers and select the app that you want to add Universal Links support to.
-
In the Capabilities menu, check the Associated Domains checkbox, and click Save.
- To add the "Associated Domains" entitlement to your app:
-
In XCode, go to Project settings > Capabilities > Associated Domains.
-
Add your Singular Links domains.
-
- Copy your "App Prefix" (AKA "Team ID") from the Apple Developer Portal.
-
In Singular, go to Apps Configuration, find your app, expand the iOS app site settings, and paste the value in the Team ID field. This will allow Singular to host the apple-app-site-association file in your Singular domain for the Universal Links.
-
Note: This step is required in cases where Universal Links cannot deep link. Read more about Universal Links deep link limitations here.Additionally below the "Team ID", enter in your iOS app's "App Scheme" to enable deep linking with traditional app scheme deep links as a fallback to Universal Link deep linking.
If this is the first time your app is supporting an iOS app scheme for deep linking, make sure the app scheme is registered in as a "URL Type" in your Xcode project:
For more information on supporting app schemes for your iOS app, see Apple's developer help article on the topic. - Now you can implement deep linking in your app according to the appropriate SDK integration guide:
Android Prerequisites
- Configure at least one sub-domain for your links in the Link Management page in Singular. For more information, see the Singular Links FAQ.
- To configure your Android app to handle URI Scheme deep links, add an appropriate intent filter to your AndroidManifest.xml.
For example:
<activity android:name=".MainActivity" android:exported="true" ... <intent-filter> <data android:scheme="singular-example"/> <action android:name="android.intent.action.VIEW"/> <category android:name="android.intent.category.DEFAULT"/> <category android:name="android.intent.category.BROWSABLE"/> </intent-filter> </activity>
This configuration will allow your app to open links such as:
singular-example://your-sub-domain1.sng.link/Aabcd/1234
-
In Singular, go to Settings > Apps, find your app, expand the Android app site settings, and enter the Android scheme name in the Android App Scheme field (in the example above, the scheme name is “singular-example”).
- Now you can implement deep linking in your app according to the appropriate SDK integration guide: