Skip to content
pubscout

share_handler

0.0.25, released a year ago by shoutsocial.com

Flutter plugin to receive incoming shared text, files, and media from other apps.

Quiet but busy
$ flutter pub add share_handler
Source repository

What it does

Enables Flutter applications to handle incoming shared content such as text, URLs, images, and videos from the system share sheet on iOS and Android. It also provides APIs to record conversations to populate direct share suggestions and shortcuts.

AI-written summary of version 0.0.25, based on the package's README and metadata. Report an inaccuracy

Use it when

  • Your app needs to receive text, links, or files shared from other applications via the native share sheet
  • You want to support direct sharing into specific conversation targets or shortcuts

Skip it when

  • You only need to trigger outgoing shares to other apps (use an outgoing share package instead)
  • Desktop or web platforms are required, as it only supports Android and iOS

Strengths

  • Supports both initial shared media when launched and real-time streaming updates when running
  • Provides built-in integration for iOS Share Extensions and Android direct share targets
  • Handles multiple media types including images, videos, URLs, text, and documents

Weaknesses

  • Requires extensive native iOS and Android configuration including creating an iOS Share Extension and App Groups
  • No support for desktop or web platforms

Setup

Kind
Plugin (native code)
Effort
High
Code generation
No
Direct dependencies
3

Requires extensive native setup: creating an iOS Share Extension target, configuring App Groups and URL schemes in Info.plist, adjusting Podfiles, and defining intent filters and shortcut XML in Android.

final handler = ShareHandlerPlatform.instance;
final initialMedia = await handler.getInitialSharedMedia();

handler.sharedMediaStream.listen((SharedMedia media) {
  print("Shared text: ${media.content}");
  print("Shared files: ${media.attachments?.length}");
});

Alternatives

Packages that do the same job and could replace share_handler.