Casa Mobile App BuilderHelp centerShopify App Store

Set up Firebase for push notifications

Create a free Firebase project, add your Android and iOS apps, and upload your private key so you can send notifications.

Push notifications are delivered by Firebase Cloud Messaging, Google's free messaging service. You set up your own Firebase project once, in three steps, and the Push notifications page shows exactly what's still missing. It takes about 15 minutes.

Connect Firebase section with three steps: create a project, upload the Android and iOS files, and upload the private key
Push notifications → Connect Firebase to send notifications.

You need a Google account, and for iPhones an Apple Developer account. Keep the Push notifications page open in one tab and the Firebase console in another.

1. Create a Firebase project

  1. Open the Firebase console and sign in with your Google account.
  2. Click Create a new Firebase project, enter a name such as your store's name, and click Continue.
  3. Google Analytics is optional, so you can turn it off. Click Create project, wait a moment, then click Continue.
Firebase create project screen with a project name entered
Name your project. The ID underneath is filled in for you.

Back on the Push notifications page, step 1 shows your app's package name. You use it for both the Android and the iOS app. If you haven't chosen one yet, set it right there.

ImportantThe package name can't be changed after your app is published, so choose it carefully.

2. Add your Android and iOS apps

In Firebase, click the gear icon next to Project Overview, choose Project settings, and stay on the General tab. Under Your apps, click Add app.

Firebase Add app dialog with iOS, Android and other platform buttons
Add app: choose Android first, then come back for iOS+.

Android

  1. Choose the Android icon.
  2. Paste your package name into Android package name exactly as shown on the Push notifications page, then click Register app.
  3. Click Download google-services.json. You can skip the remaining Firebase steps.
  4. On the Push notifications page, drop the file into Upload google-services.json.
Add Firebase to your Android app form with the package name filled in
Use your app's package name, not the example.

iOS

  1. Back in Project settings → General, click Add app again and choose iOS+.
  2. Paste the same package name into Apple bundle ID, then click Register app.
  3. Click Download GoogleService-Info.plist and drop it into Upload GoogleService-Info.plist on the Push notifications page.
TipLost a file? Both apps are listed under Your apps in Project settings, with a download link for their file.
Your apps list in Firebase project settings with the google-services.json download link
Your apps: download a file again at any time.

Let iPhones receive notifications: in Firebase, open the Cloud Messaging tab and scroll to Apple app configuration. Under APNs Authentication Key, click Upload and add your APNs key (.p8), with its Key ID and your Team ID. If you don't have a key yet, create one under Keys in the Apple Developer portal with Apple Push Notifications service (APNs) turned on.

Firebase Cloud Messaging Apple app configuration with APNs authentication key upload buttons
Cloud Messaging → Apple app configuration.
ImportantWithout the APNs key, notifications reach Android phones but not iPhones.

3. Upload your private key

  1. In Firebase, open Project settings → Service accounts.
  2. Click Generate new private key, then Generate key. Your browser downloads a .json file with a name like your-project-firebase-adminsdk-abc12.json.
  3. On the Push notifications page, drop that file into Upload private key (.json).
Firebase Service accounts tab with the Generate new private key button
Service accounts → Generate new private key.
ImportantUpload the private key here, not google-services.json. Keep the key private: anyone who has it can send messages from your Firebase project. After uploading, you can delete it from your computer.

You're connected

Once the key is uploaded, the page shows Firebase is connected and you can send your first notification. The Android and iOS files are used in your app's next build, so publish an update if your app is already live.

Firebase Configuration section showing Firebase is connected with both app files uploaded
Connected, with both app files in place.

To switch Firebase projects later, upload the new project's private key and both app files in this section. All three must come from the same project.

TipStuck on any step? Use Chat with our team under the steps and we'll help you finish the setup.
Next articleChange app text and add languages →