Getting Started

This is a developers’ guide for setting up the Airship SDK for Flutter apps.

The Airship Flutter module allows a developer to integrate push notification services with Flutter apps targeting both Android and iOS. This module is designed to be cross-platform, and applications using it can leverage the same code on both platforms.




  • Xcode 13+
  • minimum deployment target iOS 11+


  • minSdkVersion 21+
  • compileSdkVersion 31+


  1. Add the airship dependency to your package’s pubspec.yaml file:

  airship_flutter: ^5.1.1
  1. Install your flutter package dependencies by running the following in the command line at your project’s root directory:
flutter pub get
  1. Import airship into your project:
import 'package:airship_flutter/airship_flutter.dart';

Android Setup

  1. Download the Firebase google-services.json file and place it inside android/app.

  2. Apply the plugin to the android/app.

  3. Create a new file with your application’s settings and place it inside the android/app/src/main/assets directory:

   developmentAppKey = Your Development App Key
   developmentAppSecret = Your Development App Secret

   productionAppKey = Your Production App Key
   productionAppSecret = Your Production Secret

   # Toggles between the development and production app credentials
   # Before submitting your application to an app store set to true
   inProduction = false

   # LogLevel is "VERBOSE", "DEBUG", "INFO", "WARN", "ERROR" or "ASSERT"
   developmentLogLevel = DEBUG
   productionLogLevel = ERROR

   # Notification customization
   notificationIcon = ic_notification
   notificationAccentColor = #ff0000

   # Optional - Set the default channel
   notificationChannel = customChannel

EU Cloud Site

If your app uses Airship’s EU cloud site, you will need to add that to

   # EU Cloud Site
   site = EU

iOS Setup

  1. Add the following capabilities to your application target:
  • Push Notifications
  • Background Modes > Remote Notifications
  1. Create a plist AirshipConfig.plist and include it in your application’s target:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "">
<plist version="1.0">
  <string>Your Development App Key</string>
  <string>Your Development App Secret</string>
  <string>Your Production App Key</string>
  <string>Your Production App Secret</string>

Make sure that the iOS deployment target version (specified in Xcode) and the platform version (specified in your app’s Podfile) both match the current minimum target version. Mismatch between these versions can cause an “‘airship_flutter’ not found” error.

EU Cloud Site

If your app uses Airship’s EU cloud site, you will need to add that to AirshipConfig.plist.


Notification Service Extension

To take advantage of notification attachments, such as images, animated gifs, and video, you will need to create a notification service extension.

Follow the CocoaPods steps in the iOS Notification Service Extension Guide.


Flutter doesn’t enable bitcode by default, but bitcode is the default for new targets created manually in Xcode (such as your notification service extension). If any target uses bitcode, then all of them must use bitcode or the archival process will fail with a bitcode error. To resolve this issue, choose one of the following two options:

  • If your app doesn’t require bitcode support, you can disable it in your notification service extension in Xcode by setting Enable Bitcode to NO in the extension target’s Build Settings.
  • If your app does require bitcode support, you can edit your app’s Podfile to enable it for all the targets, using a post_install hook at the end of the file:
post_install do |installer|
  installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
      config.build_settings['ENABLE_BITCODE'] = 'YES'

Send Your First Push Notification

At this point in the guide, if you followed all the steps above you should be ready to send a test push notification to verify everything is set up properly.

Before sending a push, you must enable user notifications. The plugin does not enable user notifications by default in order to avoid prompting the user for permissions. But for a testing purposes, you can enable user notifications as soon as the application is ready. You may also want to set default foreground presentation options to display the notification in the foreground on iOS.

Enable user notifications