This guide walks you through installing the @smler/deferred-link React Native SDK and configuring it for both Android and iOS.
Requirements
React Native 0.60+ (auto-linking supported)
Android:
minSdkVersion 21,compileSdkVersion 34iOS: iOS 13.0+
TypeScript 5.0+ (recommended, but not required)
Install the Package
npm install @smler/deferred-link
# or
yarn add @smler/deferred-linkiOS Setup
After installing the npm package, install the native CocoaPods dependency:
cd ios && pod installThat's it for iOS. The native module is auto-linked. The iOS deep link detection logic runs entirely in JavaScript — it reads the clipboard and performs pattern matching without any additional native configuration.
Important: iOS Clipboard Access
React Native's built-in Clipboard module is used by default. If you are on a newer React Native version where Clipboard has been extracted from core, install the community module:
npm install @react-native-clipboard/clipboardAndroid Setup
No additional configuration is required on Android. The SDK automatically bundles the Google Play Install Referrer library (com.android.installreferrer:installreferrer:2.2) as a dependency.
The native Android module is written in Kotlin and handles the full Install Referrer lifecycle internally — including connection management, result caching, retry on disconnect, and error handling. Your JavaScript code only needs to call a single async method.
Peer Dependencies (Optional)
Probabilistic Matching
For device-fingerprint-based probabilistic matching (fallback attribution when clipboard or referrer methods are not available), install react-native-device-info:
npm install react-native-device-infoIf this package is not installed, probabilistic matching will still work but will send "Unknown" for the device and OS fields, which reduces match accuracy.
Verify Installation
Import the SDK in your app to verify it is linked correctly:
import { SmlerDeferredLink, HelperReferrer } from '@smler/deferred-link';
// If this doesn't throw, the native module is linked correctly
console.log('Smler SDK loaded');If you see an error like "The package 'react-native-smler-deferred-link' doesn't seem to be linked", check the following:
You have run
pod installin theios/directoryYou rebuilt the app after installing the package (a hot reload is not sufficient)
You are not using Expo Go — use a development client or bare React Native workflow
What's Next
Android — Install Referrer: Read referral data on Android after a new install.
iOS — Clipboard Deep Links: Detect deep links from the iOS clipboard.
Resolving Deep Links: Resolve Smler short links at runtime.