--- title: "Handle universal links" slug: "handle-universal-links" description: "Complete the App Links package integration to integrate universal links in your Flutter project." tags: ["flutter cart reminder"] updated: 2026-11-04T13:13:35Z published: 2026-11-04T13:13:35Z canonical: "academy.insiderone.com/handle-universal-links" --- > ## Documentation Index > Fetch the complete documentation index at: https://academy.insiderone.com/llms.txt > Use this file to discover all available pages before exploring further. # Handle universal links ## Handle with "App Links" Plugin To integrate Universal Link in your Flutter project, complete the App Links package integration following [App Links](https://pub.dev/packages/app_links). To capture URLs with the App Links plugin, follow the package's developer guide. [Android Guide ReadMe.](https://github.com/llfbandit/app_links/blob/master/doc/README_android.md) [iOS Guide ReadMe.](https://github.com/llfbandit/app_links/blob/master/doc/README_ios.md) Direct the URLs you captured to the **handleUniversalLink** method in the Insider plugin in Dart. Starting with **flutter_insider 5.5.0**, handleUniversalLink returns a Future that completes when the native SDK call has returned. You can await it before you run the next step. For details, see [Await SDK Calls](https://academy.insiderone.com/docs/flutter-await-sdk-calls). ```dart final appLinks = AppLinks(); final sub = appLinks.uriLinkStream.listen((uri) async { await FlutterInsider.Instance.handleUniversalLink(uri); print('[INSIDER][uriLinkStream]: $uri'); }); ``` If the app is opened with a URL when in a killed state, the Insider plugin might not collect the universal link via the handleUniversalLink method. This could happen because the Insider SDK has not yet been initialized. In such cases, you can use the code above after the Insider plugin initializes, or add a delay when calling the handleUniversalLink method. ## Handle with Native Methods ### Android If necessary, review the URLs in AndroidManifest.XML. Please check [here](https://developer.android.com/training/app-links/deep-linking#adding-filters). After adding the intent filter to the AndroidManifest.xml, you need to include the Insider handleUniversalLink methods in the MainActivity class, as shown below. If an error occurs during compilation stating that the Insider methods cannot be found, you need to manually add the Insider SDK to the app-level build.gradle file. Make sure the version you add matches the version used in the plugin to avoid any conflicts. implementation 'com.useinsider:insider:X.X.X' ```dart package com.example.flutter_demo import android.content.Intent import android.os.Bundle import io.flutter.embedding.android.FlutterActivity import com.useinsider.insider.Insider class MainActivity: FlutterActivity() { override fun onResume() { super.onResume() Insider.Instance.handleUniversalLink(getIntent()) } override fun onNewIntent(intent: Intent) { super.onNewIntent(intent) Insider.Instance.handleUniversalLink(intent) } } ``` ### iOS For iOS, the universal link swizzle method works automatically, so no additional action is required on your part. However, if you encounter any issues, you can apply the manual integration as shown below. Add the Insider **handleUniversalLink** iOS method in the **continueUserActivity** method that you added to the AppDelegate. If an error occurs during compilation stating that the Insider methods cannot be found, you need to import the Insider package to the {ProjectName}-Bridging-Header.h. ```dart import UIKit import Flutter @UIApplicationMain @objc class AppDelegate: FlutterAppDelegate { override func application( _ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? ) -> Bool { ... } // For handling universal links override func application( _ application: UIApplication, continue userActivity: NSUserActivity, restorationHandler: @escaping ([UIUserActivityRestoring]?) -> Void ) -> Bool { // For universal links Insider.handleUniversalLink(userActivity) return super.application(application, continue: userActivity, restorationHandler: restorationHandler) } } ``` ## Related - [Events](/flutter-default-mobile-events.md)