- An FCM Service Account private key, uploaded to OneSignal. This authorizes OneSignal’s servers to send to your Firebase project. Required.
- A
google-services.jsonfile, added to your app. This is Firebase client configuration that ships inside your app. Recommended for all new integrations, and required for Firebase Installation ID registration. See Add your Firebase configuration file.
- Web Push. Android devices can subscribe to your website or PWA without an FCM Service Account. See Web push setup.
- Huawei apps distributed via the Huawei App Gallery. See Huawei Authorization.
- Amazon apps distributed via the Amazon Appstore. See Amazon API key generation.
Requirements
- An Android app distributed via the Google Play Store
- A OneSignal account
- A Firebase account (free)
- A Firebase Service Account private key with the
cloudmessaging.messages.createandfirebase.projects.getpermissions- If you do not have one, follow the steps below to create a Firebase Service Account private key
- If you already have a private key, check existing permissions
- A
google-services.jsonfile from the same Firebase project, added to your app. Recommended for all new integrations. See Add your Firebase configuration file
Create a Firebase Service Account private key
Create or open your Firebase Project

Page of Projects within Firebase
Enable Firebase Cloud Messaging API V1

Cloud Messaging tab in Firebase Project settings
- Enabled (green checkmark) means Google accepts Cloud Messaging send requests for this project.
- Disabled means Google rejects those requests, so Android push notifications do not deliver. Enable this by clicking the 3-dot menu > Manage API in Google Cloud Console, then click Enable and wait until the status shows API Enabled with a green checkmark.

Firebase Cloud Messaging API enabled in the Google Cloud Console
Generate a new private key

Service Accounts section within Firebase

Generate the private key for the service account.
.json file in a secure location. You will need it in the next section.Upload the Service Account private key to OneSignal
In your OneSignal dashboard:Open Android settings

Platforms screen within OneSignal app settings
Upload your Service Account private key
.json private key you saved in the previous section.
FCM configuration screen
Save and continue
Add your Firebase configuration file
Your app needsgoogle-services.json from the same Firebase project as the Service Account above. This is recommended for all new Android integrations. Your app may already have this file, but if not, these steps will guide you through the process.
google-services.json tells your app which Firebase project to register with. Both come from the same project.5.11.0 and later, push registers through your app’s own Firebase project instead of OneSignal’s shared one. It is also required for Firebase Installation ID registration.
Download google-services.json
applicationId.Download google-services.json.Add it to your app
Apply the Google Services Gradle plugin
google() is listed under pluginManagement in settings.gradle or settings.gradle.kts, or the build fails with Plugin [id: 'com.google.gms.google-services'] was not found:Verify the file took effect
google_app_id and project_id is the proof that the file took effect. A build that succeeds is not.- The plugin is what makes the file take effect. It converts
google-services.jsoninto resources Firebase reads at runtime. Adding the file without applying the plugin does nothing, and produces no error. - If the build fails with
File google-services.json is missing, the plugin is applied but the file is not where your toolchain expects it. Check the table above. - If the build fails with
No matching client found for package name, the package registered in Firebase does not match yourapplicationId. Fix it in the Firebase console and download the file again. - If the two files come from different Firebase projects, Android Subscriptions show status
-6. See Verify your Firebase project matches.
Verify your Firebase project matches
The Firebase project your app registers against must be the same project as the FCM Service Account uploaded to OneSignal. If they differ, Android Subscriptions show status-6, and existing Subscriptions are marked invalid.
Compare these two values:
google-services.json looks like this:
client_info.android_client_info.package_name must also match your app’s applicationId. If it does not, the Google Services Gradle plugin fails your build with No matching client found for package name. Register the package in your Firebase project, or download the correct google-services.json.FAQ
How do I check my Service Account permissions?
Service Account roles are granted on the IAM page in the Google Cloud Console, not in the Firebase Console and not on the Service Accounts page. The Service Account whose private key you upload to OneSignal must have both:cloudmessaging.messages.create— granted by Firebase Cloud Messaging API Admin (roles/firebasecloudmessaging.admin).firebase.projects.get— granted by Firebase Viewer (roles/firebase.viewer).
roles/firebase.admin), Editor, or Owner include both permissions and also satisfy the requirement. For OneSignal-only Service Accounts, prefer the narrow pair above to limit the impact if the private key is ever exposed.
If the OneSignal dashboard shows Invalid request after you upload your Service Account private key, missing roles are the most common cause.
Open the IAM page
Find your Service Account
client_email field in the private key you uploaded. It looks like firebase-adminsdk-xxxxx@YOUR_PROJECT_ID.iam.gserviceaccount.com. Paste that email into the filter box if the table is long.Add any missing roles
- Firebase Cloud Messaging API Admin
- Firebase Viewer
Save
Why am I seeing “This configuration is for a different Firebase Project”?
This error occurs when the uploaded private key belongs to a different Firebase project (a different Sender ID). Solution: Use the original Firebase project’s private key. If unavailable, contactsupport@onesignal.com with your App ID. Switching projects resets push tokens. Your users must reopen the app to get push again.
The same mismatch can happen in the other direction: the uploaded key is correct, but the app ships a google-services.json from a different Firebase project. Android Subscriptions then show status -6. See Verify your Firebase project matches.
Can I change my Sender ID?
Yes, but it will impact your existing users. Device tokens are tied to the original Sender ID. Changing it will invalidate existing tokens. If you need help, contactsupport@onesignal.com with your App ID.
Why don’t I see a Sender ID in OneSignal?
If your Firebase server key looks likeAIz..., you’re likely using an outdated Google Cloud Messaging (GCM) setup. Create a new Firebase project and upload a Service Account private key.
Do I need to update my code when switching to FCM V1?
No app or SDK changes are required. This is a dashboard-only update.Are the legacy FCM APIs still supported?
No. Google’s legacy FCM APIs are fully deprecated and no longer deliver notifications. If your app still uses them, upload a Service Account private key as described above to move to FCM V1.How can I check which apps are still using the Legacy API?
Call the View an app API for each app and check thefcm_v1_service_account_json field in the response:
- Present and non-empty: the app is on FCM V1.
- Missing or empty: the app is not configured for FCM V1. If the app sends Android push, it is still on the Legacy API and must be migrated.