app_links

7.2.2

Android App Links, Deep Links, iOs Universal Links and Custom URL schemes handler for Flutter (desktop included).

Download archive

Readme

app_links

Android App Links, Deep Links, iOS Universal Links and Custom URL schemes handler (desktop included linux, macOS, Windows).

This plugin allows you to open your app from:

  • HTTPS URLs instead of the browser.
  • custom schemes.

Getting Started

Before using the plugin, you'll need to setup each platform you target.

All those configurations below are also accessible in the example project.


AppLinks usage

Please, ensure to instantiate AppLinks early in your app to catch the very first link when the app is in cold state.

final appLinks = AppLinks(); // AppLinks is singleton

// Subscribe to all events (initial link and further)
final sub = appLinks.uriLinkStream.listen((uri) {
    // Do something (navigation, ...)
});

Feature matrix

Feature Android iOS web Windows macOS linux
web (https://) ✔️ ✔️ ✔️* ✔️ ✔️ ?
custom scheme (foo://) ✔️ ✔️ ✔️ ✔️ ✔️

* : Only the very first call is provided. Web platform is mostly provided to get rid of specific setup.

Changelog

7.2.2

  • fix: Send all links received before the first listen, not just the first one.
  • fix(android): Stop resending the launch link when the activity is rebuilt.
  • fix(windows): Reliable link forwarding to the running instance.
  • fix(windows): Remove ineffective WM_COPYDATA sender check.
  • fix(ios): Fix link handling edge cases.
  • fix(ios): Stop sending links once per engine.
  • fix(ios): Give each engine its own link stream.
  • fix(macos): Share custom scheme URLs with other plugins and support engines created after launch.
  • fix(macos): Give each engine its own link stream.

7.2.1

  • fix(Android): Remove debug log.
  • fix: Comments lost in front-facing API.

7.2.0

  • feat(windows): export SendAppLinkToInstance from plugin to remove setup boilerplate.
    • find the existing window automatically, removing the need to pass the window title.
    • Go to Windows setup docs.

7.1.2

  • fix: AppLinks doesn't extend AppLinksPlatform anymore.
  • fix: Prevent app crash on malformed URI.
  • fix: controller.close() permanently kills controller.
  • fix(Android): Remove debug log.
  • chore(Darwin): Code improvement.
  • fix(Windows): latestlink always null on cold start.
  • fix(Windows): WM_COPYDATA unbounded read + any-process URI injection.
  • fix(Windows): correct cbData to use UTF-8 byte count.

7.1.1

  • fix(Android): Build issue.

7.1.0

  • chore: Updates minimum supported SDK version to Flutter 3.44/Dart 3.12.
  • Android:
    • chore: Move to AGP 9.x.
    • chore: Move to Kotlin Gradle DSL.
  • iOS:
    • chore: Completes Swift Package Manager integration.
  • macOS:
    • chore: Completes Swift Package Manager integration.
  • Windows:
    • chore: Remove dead code.
    • chore: Updates example project win32 dependency to 6.x.

7.0.0

This version focuses on Flutter 3.38 release and especially iOS scene lifecycle breaking changes with few tools for easier customization.

This version is still backward compatible with v6 setups.

Flutter UIScene migration doc.

  • chore(iOS) Breaking: Flutter 3.38.1 is now the minimum version.
  • chore(iOS) Breaking: iOS 13 is now the minimum version.
  • feat(iOS): Adds support for global and local event propagation handling.
  • feat(iOS): Adds support for internal or external UISceneDelegate.
  • feat(iOS): Adds enabled flag to disable automatic link handling.
  • chore(Android): Dependency updates to align with Flutter 3.38.1.

6.4.1

  • chore(Android): Remove Firebase Dynamic Links feature (see FAQ).
  • chore(Android): Update Gradle settings.
  • chore(Android): Update Java 8 to 11.
  • chore(Android): Min SDK is now 21.
  • chore(Android): Update Example project settings.
  • fix(iOS): Cancel plugin registration and print a message to workaround EXC_BAD_ACCESS crash when running debug mode and not attached to debugger anymore.
  • chore: Update minimum supported SDK version to Flutter 3.24.0/Dart 3.5.0.

6.4.0

  • chore(iOS): Support Swift Package Manager.
  • chore(macOS): Support Swift Package Manager.
  • fix(iOS): Relax condition to forward Universal Links.
  • chore(Android): Bump android min SDK version to 19.

6.3.3

  • fix(windows): Allow other plugins to handle window messages.

6.3.2

  • fix(windows): Revert main.cpp modifications.

6.3.1

  • fix(Windows): Open scheme detection to wider range.

6.3.0

  • feat(Windows): Handle activation from packaged app.
    • This means you can either use https://, sample://, ... protocols with related hosts.
    • More info in Windows setup docs.
  • feat(Windows): No more main.cpp modification required!
    • ⚠️ Please, remove it if you're coming from an update.
  • chore: Remove previous setup main.cpp from example.
  • chore: docs update.

6.2.1

  • fix(Android): Add ProGuard rules.
  • fix(Windows): Send link if only there's 1 argument with a scheme.
  • chore(Android): Upgrade to latest AGP 8 and compileSdk 34.
  • chore: Update dependencies to latest.
  • chore(Android): Update example setup.
  • chore(iOS): Set minimum OS version to 12.0.
  • chore: Set minimum Flutter version to 3.19.0.

6.2.0

  • feat: Allow multiple listeners.

6.1.4

  • fix: Channel method names.

6.1.3

  • chore: Update dependency app_links_platform_interface to 2.0.0+ because of breaking changes.

6.1.2

  • fix: WASM compilation by re-introducing partial federated structure.
  • fix: Platforms with dependencies are now isolated in a dedicated package.
  • chore: Makes example project compatible with WASM compilation.

6.1.1

  • fix: README.md doc links.

6.1.0

  • feat(macOS): Handle universal links. See README.md for setup.
  • chore: Cleanup README.md.

6.0.2

6.0.1

  • fix(linux): Initialization process.

6.0.0

  • Breaking: Replaced allStringLinkStream by stringLinkStream and allUriLinkStream by uriLinkStream.
  • Breaking: Removed allStringLinkStream, allUriLinkStream.
    The changes above should clarify the usage of the plugin. Both streams handle initial and further links.
  • Breaking: Renamed getInitialApp* and getLatestApp* methods to getInitialLink* and getLatestLink*.
  • chore(QoL): The plugin should not send again initial link when restarting, reloading the app or subscribing again to the stream.
  • fix(macOS): Handle link from cold state (i.e. terminated).
  • fix(linux): Refactor code to not store all URIs.
  • fix(linux): Stream is not filled anymore when there's no listener.

5.0.0

  • Breaking iOs: Application Delegate now returns true for both Universal Links and Custom URL schemes. If you have other packages which could conflict with it, report to the README.md for custom handling. This change is motived by the basic deep linking provided by Flutter and the fact that there is now a workaround for such cases.

4.0.1

  • fix(Android): Reworked capture by explicitly discarding ACTION_SEND* and let other basic actions succeed (NFC for example).

4.0.0

  • Breaking fix(Windows): Updated setup to be more resilient to Flutter changes. Can work with v3 but mandatory from Flutter 3.19 with new projects.
  • Breaking chore(Android): Remove capture of ACTION_SEND to avoid conflicts with others packages.
  • Breaking chore(web): move from dart:html to package:web to allow WASM compilation.
  • chore: Updated setup for iOS to handle result while other packages are around.

3.5.1

  • chore: Add privacy manifest to iOS and macOS platforms.

3.5.0

  • feat: Add linux support.
  • fix(macOS): Flutter 3.16 broke macOS behaviour.
  • fix(iOS): Allow to call AppLinks plugin from outside for custom AppDelegate or SceneDelegate.
  • chore: README update.

3.4.5

  • fix(Android): Code improvements and correctly skip event firing when comming from history.

3.4.4

  • fix: Add missing allUriLinkStream and allStringLinkStream methods web platform.

3.4.3

  • chore: Add support for Flutter 3.10.
  • chore(Android): Add support for AGP 8.0.
  • fix(iOS): Code improvements (Thanks to michalsrutek)

3.4.2

  • chore: Merge platform interface in main project.

3.4.1

  • fix(macOS): wrong plugin definition resulting in build errors.

3.4.0

  • feat(Android): Allow ACTION_SEND with Intent.EXTRA_STREAM, Intent.EXTRA_TEXT. (thanks to espresso3389)
  • feat: Add single stream for all links (See README for updated usage).
  • chore: Unify platform packages in app_links main package (Windows #include directive must be updated!).
  • chore: Remove duplicated code in windows implementation.

3.3.0

  • feat: Triggering Firebase dynamic links for Android >= 12 (behaviour changes). (thanks to AdrienAudouard)

3.2.0

  • feat: Add macOS support.

3.1.0

  • feat: Add Windows support.

3.0.2

  • fix: iOS application callbacks do not return true anymore.

3.0.1

  • core: Improve Android code.

3.0.0

  • core: Breaking API changed to use stream instead of callback.
  • fix: Consistent behaviour between iOS & Android with (deffered) stream usage (for onAppLink vs. getInitialLink "duplicated" links).
  • fix: remove example splashscreen deprecation.

2.2.2

  • core: Add linter.
  • fix: Get rid of Android LocalBroadcastReceiver deprecation (removed dependency & import...).

2.2.1

  • fix: Duplicated iOS call when app is on terminated status.
  • fix: iOS application callback does not return true anymore.
  • fix: Get rid of Android LocalBroadcastReceiver deprecation.
  • core: Updated dependencies.

2.2.0

  • Add web support. (getInitialAppLink() only).

2.1.0

  • Breaking: String uri added on onAppLink for custom handling like uppercased uri.
  • Feat: getInitialAppLinkString and getLatestAppLinkString added to reflect the above change.

2.0.0+1

  • Minimal sample added (Thanks to @JamesCullum).

2.0.0

  • Add null safety support.

1.0.0

  • Same as 0.2.0.
  • No known issue. Bumping to 1.0 to be prepared for null safety version.

0.2.0

  • Add configurations in example.

0.1.0+2

  • Update README.md.

0.1.0+1

  • Add documentation.
  • Format dart source code.

0.1.0

  • Initial release.
  • Android App Links, Deep Links, iOS Universal Links and Custom URL schemes.

Installing

export PUB_HOSTED_URL=https://pub.mirror.p-hatan.com
flutter pub add app_links
pubspec.yaml
name: app_links
description: Android App Links, Deep Links, iOs Universal Links and Custom URL schemes handler for Flutter (desktop included).
version: 7.2.2
homepage: https://github.com/llfbandit/app_links

environment:
  sdk: ^3.12.0
  flutter: ">=3.44.0"

resolution: workspace

dependencies:
  flutter:
    sdk: flutter
  
  app_links_linux: ^1.0.4
  app_links_platform_interface: ^2.0.4
  app_links_web: ^1.0.5

dev_dependencies:
  flutter_lints: ^6.0.0

flutter:
  plugin:
    platforms:
      android:
        package: com.llfbandit.app_links
        pluginClass: AppLinksPlugin
      ios:
        pluginClass: AppLinksIosPlugin
      linux:
        default_package: app_links_linux
      macos:
        pluginClass: AppLinksMacosPlugin
      web:
        default_package: app_links_web
      windows:
        pluginClass: AppLinksPluginCApi

topics:
  - deeplink
  - app-links
  - universal-links
  - custom-url-schemes
  - web-to-app

Version history

VersionPublishedArchiveSHA-256
0.1.0Cached · Upstream SHA-256 matchedDownload07891d9d…8285a8
0.1.0+1Cached · Upstream SHA-256 matchedDownload86542ee4…50d501
0.1.0+2Cached · Upstream SHA-256 matchedDownload2ec3d04c…2af9d4
0.2.0Cached · Upstream SHA-256 matchedDownloadbecd0893…97c3d0
1.0.0Cached · Upstream SHA-256 matchedDownload2c0b508b…c91682
2.0.0Cached · Upstream SHA-256 matchedDownloada3bc0cfb…9a8176
2.0.0+1Cached · Upstream SHA-256 matchedDownloadcf0bb213…342014
2.1.0Cached · Upstream SHA-256 matchedDownload8952ce08…a65c01
2.2.0Cached · Upstream SHA-256 matchedDownload02d5b116…dd18f7
2.2.1Cached · Upstream SHA-256 matchedDownload4af01185…c78234
2.2.2Cached · Upstream SHA-256 matchedDownloadde064ea9…db2f1c
3.0.0Cached · Upstream SHA-256 matchedDownloadfcf08826…f3bb35
3.0.1Cached · Upstream SHA-256 matchedDownloadbbe434aa…d35163
3.0.2Cached · Upstream SHA-256 matchedDownload24feda5b…787688
3.1.0Cached · Upstream SHA-256 matchedDownload7a28970b…8db7f2
3.2.0Cached · Upstream SHA-256 matchedDownloadcbf1dbb4…33ecfe
3.3.0Cached · Upstream SHA-256 matchedDownloadd1b2cf9a…e36a0d
3.4.0Cached · Upstream SHA-256 matchedDownloada669e117…da4df2
3.4.1Cached · Upstream SHA-256 matchedDownload0ae67296…0d1e8e
3.4.2Cached · Upstream SHA-256 matchedDownloadd572dcdf…c1b5e8
3.4.3Cached · Upstream SHA-256 matchedDownload16725e71…6a4cb6
3.4.4Cached · Upstream SHA-256 matchedDownloadf41abc50…80abd5
3.4.5Cached · Upstream SHA-256 matchedDownloadeb83c2b1…ef0dae
3.5.0-beta.1Cached · Upstream SHA-256 matchedDownloadb577f5af…703122
3.5.0-beta.2Cached · Upstream SHA-256 matchedDownload6604788c…0ac535
3.5.0-beta.3Cached · Upstream SHA-256 matchedDownload1e1e917e…e5cef8
3.5.0Cached · Upstream SHA-256 matchedDownload4e392b5e…74a3bb
3.5.1Cached · Upstream SHA-256 matchedDownload3ced568a…0cada4
4.0.0Cached · Upstream SHA-256 matchedDownloadfd7fc156…88bb5f
4.0.1Cached · Upstream SHA-256 matchedDownload42dc15ae…08c815
5.0.0Cached · Upstream SHA-256 matchedDownload0fd41f05…eeb121
6.0.0Cached · Upstream SHA-256 matchedDownloadf57cf388…ca3a9f
6.0.1Cached · Upstream SHA-256 matchedDownload1c2b9e9c…53d001
6.0.2Cached · Upstream SHA-256 matchedDownload8c6ef5ba…e736c9
6.1.0Cached · Upstream SHA-256 matchedDownloadc7b2c446…9a0cc1
6.1.1Cached · Upstream SHA-256 matchedDownload96e67781…5eb3db
6.1.2Cached · Upstream SHA-256 matchedDownload49117eef…9e7a14
6.1.3Cached · Upstream SHA-256 matchedDownloada9905d6a…c4f06b
6.1.4Cached · Upstream SHA-256 matchedDownloadae5f9a1b…70c4af
6.2.0Cached · Upstream SHA-256 matchedDownload4acba851…ceb0c7
6.2.1Cached · Upstream SHA-256 matchedDownloadf04c3ca9…305e21
6.3.0Cached · Upstream SHA-256 matchedDownload50437e59…e1c5ea
6.3.1Cached · Upstream SHA-256 matchedDownload7e058edb…93a491
6.3.2Cached · Upstream SHA-256 matchedDownloadad1a6d59…84dd99
6.3.3Cached · Upstream SHA-256 matchedDownload433df2e6…be7950
6.4.0Cached · Upstream SHA-256 matchedDownload85ed8fc1…bb54ba
6.4.1Cached · Upstream SHA-256 matchedDownload5f884475…cee3e8
7.0.0Cached · Upstream SHA-256 matchedDownload3462d9de…8a7abc
7.1.0Cached · Upstream SHA-256 matchedDownloada408901c…7a4e4f
7.1.1Cached · Upstream SHA-256 matchedDownloada350a5b3…483c18
7.1.2Cached · Upstream SHA-256 matchedDownload4ec328cd…7f1315
7.2.0Cached · Upstream SHA-256 matchedDownload9d3c82f6…780dbe
7.2.1Cached · Upstream SHA-256 matchedDownloadf8db46d2…1188ea
7.2.2Cached · Upstream SHA-256 matchedDownload08ba88bf…bc69c3

Dependencies

app_links_linux "^1.0.4"

app_links_platform_interface "^2.0.4"

app_links_web "^1.0.5"

flutter { "sdk": "flutter" }