Skip to main content
Set up the OneSignal SDK to send push notifications and in-app messages to your Android, iOS, Huawei, and Amazon apps. The same SDK also supports Live Activities on iOS and Live Updates on Android. For websites, see Web SDK setup. Setup has two requirements. You can complete them in either order:
  1. Get platform credentials and save them in OneSignal: FCM for Android, APNs for iOS, HMS for Huawei, and ADM for Amazon.
  2. Integrate the SDK: install the OneSignal SDK for your platform and initialize it with your App ID.

Get platform credentials

Push requires credentials from each platform you support. You can install the SDK before you have them. The SDK still creates users and shows in-app messages, and push starts delivering once you save the credentials.

Android (Google Play)

Use for Android apps on Google Play or any Android build that uses Google Play services. Create an FCM Service Account key in Firebase.

iOS

Use for every iOS build, including App Store, TestFlight, and development. Create a .p8 key, which does not expire.

Huawei (AppGallery)

Use for apps on Huawei AppGallery or Huawei devices without Google Play services. Copy your Client ID and Secret from AppGallery Connect.

Amazon (Appstore)

Use for Fire OS apps on the Amazon Appstore. Create OAuth credentials and an API key in the Amazon Developer Console.
Push notifications do not deliver to a platform until its credentials are saved in Settings > Push & In-App. Each store uses its own credentials, so set up every platform you distribute on.

Integrate the SDK

Which SDK should I use?

Match the SDK to the language or framework your app is built with, and to the store you distribute through.

SDK setup guides

Android native

Native Android apps using FCM.

iOS native

Native iOS apps using APNs.

Amazon Fire OS

Apps distributed on the Amazon Appstore using ADM.

Huawei

Apps distributed on Huawei AppGallery using HMS.

React Native

Bare React Native apps.

Expo

Managed Expo apps with EAS Build.

Flutter

Flutter apps using Dart.

Unity

Unity apps for iOS, Android, Amazon, and Huawei.

.NET MAUI

.NET MAUI apps for iOS and Android.

Cordova

Cordova and Ionic Cordova hybrid apps.

Capacitor

Capacitor and Ionic Capacitor hybrid apps.

Other integrations

FlutterFlow

Low-code FlutterFlow apps.

Median.co

Median.co (formerly GoNative.io) web-to-app apps.

SDK versions


Next steps

Prompt for push permissions

Ask for push permission at the right moment with an in-app message.

Test Users

Verify delivery, rendering, and deep links before sending to your full audience.

Mobile SDK reference

Methods, classes, and event hooks for iOS, Android, and cross-platform SDKs.

Mobile troubleshooting

Resolve common push delivery, APNs, and in-app messaging issues.

FAQ

Can I install the SDK before I have push credentials?

Yes. The SDK initializes, creates users, and shows in-app messages without credentials. Push notifications start delivering after you save that platform’s credentials in Settings > Push & In-App. See Get platform credentials.

Where do I find my App ID and API key?

Go to Settings > Keys & IDs in the OneSignal dashboard. The App ID is a 36-character UUID that you pass when you initialize the SDK. It is public and safe to put in your app. The SDK does not use an API key. An App API key authenticates REST API requests from your server, such as sending messages. It is a secret, so never put it in your mobile app. See Keys & IDs.

Do I need separate OneSignal apps for iOS, Android, Web, and email?

No. A single OneSignal App supports multiple platforms and channels, and they all share the same users and segments. Save push credentials for each mobile platform in Settings > Push & In-App. Email and SMS have their own setup under Settings. Use separate OneSignal Apps for separate environments, such as development, staging, and production. Each app has its own App ID, users, and messages, so test sends and test data never reach your production users. See Apps and organizations.

Can Huawei devices or devices in China receive push notifications?

Huawei devices can, through Huawei Mobile Services (HMS). Huawei devices without Google Play services, including newer Huawei phones, can only receive push through HMS. Add the Huawei SDK to that build. Other Android devices without Google Play services, including many sold in mainland China, cannot receive push through FCM. When a build includes both FCM and HMS and the device supports both, OneSignal uses FCM unless you prefer HMS.