Hitting the "app-killed / data-only FCM" problem — notifications stop showing after swiping app away on Android
Hey everyone, I'm running into the classic Android FCM "app-killed / data-only message" problem and would love any insights or confirmation from folks who've solved this.
The setup:
- React Native + Expo (or RN Firebase, depending on what you're using)
- App shows notifications by scheduling local notifications in JS after receiving an FCM data message
- When the app is in the foreground/background, notifications work fine
- When I swipe the app away (Android kills the JS runtime), notifications stop appearing
What I think is happening:
- We're sending data-only FCM messages
- Our JS background handler schedules a local notification
- Once Android kills the app (swipe-kill / force-stop), the JS runtime is gone
setBackgroundMessageHandlercan't run, so no notification is shown- Android doesn't guarantee delivery of data-only messages when the app is killed/force-stopped
What I've searched:
- "Android FCM data-only message not delivered when app is killed"
- "FCM notification vs data payload app killed"
- "React Native Firebase setBackgroundMessageHandler app killed"
- "Expo notifications background FCM app force stopped"
What I'm considering:
- Switching to an FCM payload with a top-level
notificationblock so Android displays it natively - Moving user-visible
title/bodyintonotification, keeping routing metadata indata - Creating proper Android notification channels
- Checking
android.priority: "high"for time-sensitive alerts
My question:
- Has anyone successfully made notifications appear after swipe-kill on Android with React Native/Expo?
- Is switching to a
notificationpayload the right fix, or is there a manifest/Gradle setting I'm missing? - Any Expo-specific or React Native Firebase-specific tips for handling this?
If you've solved this, I'd really appreciate:
- Your final FCM payload structure
- Any Android-side config (channels, permissions, manifest)
- Whether you're using Expo Notifications or react-native-firebase
Thanks in advance!
u/Spirited_Ice_3233 — 1 day ago