talira

flutter_local_notifications

Cross-platform Flutter plugin for displaying and scheduling local notifications

open sourceBSD-3-Clausefree

flutter_local_notifications is a Flutter plugin for displaying and scheduling local notifications on Android, iOS, macOS, Linux, Windows and the web, using each platform's own notification APIs. It shows notifications straight away, schedules them for a set time, repeats them daily, weekly or at an interval, lists pending ones and cancels them, and tells the app when a notification was tapped, including when it launched the app. Android options cover importance, priority, vibration, icons, HTML content and styles such as big picture, big text, inbox and messaging. The plugin's API isn't static, so it can be mocked in tests.

Problems it solves

  • show a local notification from a Flutter app
  • schedule a daily reminder notification in Flutter
  • know whether my Flutter app was opened by tapping a notification

Features

  • local notifications on Android, iOS, macOS, Linux, Windows and web
  • schedule notifications, daily, weekly or at an interval
  • list pending and cancel notifications
  • handle taps in the foreground, background or after termination
  • Android importance, priority, vibration, icons and notification styles
  • mockable, non-static API

Limitations

  • iOS keeps only the 64 most recently set pending notifications.1
  • On the web, notification permission can only be requested in response to a user interaction.1
  • On Linux, which features work depends on the system notification server.1

Alternatives

The same job

These do what flutter_local_notifications does.

  1. local_auth Flutter plugin for local authentication with biometrics, passcode, PIN or pattern
  2. permission_handler Request and check app permissions in Flutter

Compare flutter_local_notifications with the top 3