Skip to main content

Push Notifications on iOS

Use this guide after you have created your Firebase project and replaced the iOS GoogleService-Info.plist file.

Quick Answer

iOS push requires APNs credentials in Firebase, Push Notifications capability in Xcode, a matching bundle identifier, notification permission at runtime, and testing on a real iOS device.

Official references:

1. Confirm the iOS App Identity

Make sure these values match:

  • iOS bundle identifier in Xcode;
  • iOS app registered in Firebase;
  • Apple Developer App ID;
  • provisioning profile used by Xcode.

If the bundle identifier changes, recreate or update the Firebase iOS app and download a fresh GoogleService-Info.plist.

2. Upload APNs Credentials to Firebase

In Firebase Console:

  1. Open Project Settings.
  2. Open Cloud Messaging.
  3. Select your iOS app.
  4. Upload your APNs authentication key or APNs certificate.
  5. Confirm the Team ID and Key ID match Apple Developer.

APNs authentication keys are usually easier to maintain than certificate-based setup because one key can support multiple apps in the same Apple Developer team.

3. Enable Native Capabilities

Open the iOS project in Xcode:

  1. Select the app target.
  2. Open Signing & Capabilities.
  3. Add Push Notifications.
  4. Add Background Modes if your app needs background notification handling.
  5. Select the correct development team and provisioning profile.

4. Install Pods and Rebuild

After changing Firebase config or iOS capabilities:

cd ios
bundle exec pod install
cd ..
yarn ios

5. Test on a Real Device

At minimum:

  1. Install the app on a real iPhone.
  2. Log in.
  3. Accept notification permission.
  4. Confirm the app saves an FCM token for the user.
  5. Trigger a notification from the app flow or backend.
  6. Confirm foreground, background, and terminated-state behavior.
  7. Confirm tapping the notification opens the expected screen if deep linking is implemented.

Troubleshooting

ProblemFix
iOS never receives an FCM tokenCheck APNs credentials in Firebase, bundle identifier, GoogleService-Info.plist, and real-device testing.
Permission prompt does not appearConfirm the app requests notification permission and that permissions were not previously denied in Settings.
Android works but iOS does notCheck APNs authentication key, Team ID, Key ID, iOS bundle identifier, and Firebase iOS app mapping.
Works in debug but not TestFlightCheck production APNs credentials, provisioning profile, and release bundle identifier.
Notifications arrive but taps do nothingCheck notification payload data and navigation/deep-link handling.

Next Steps