firebasefirebase-cloud-messagingfirebase-in-app-messaging

What is the difference between Firebase Cloud Messaging and Firebase In-App Messaging


What is the difference between Firebase Cloud Messaging and Firebase In-App Messaging? They both send notifications to your app that something has happened. I took a look at their docs and these are their one-line descriptions:

Firebase Cloud Messaging:

Firebase Cloud Messaging (FCM) is a cross-platform messaging solution that lets you reliably send messages at no cost.

Firebase In-App Messaging:

Engage active app users with contextual messages.

They both send messages to the app. What is the difference between them and when should I use one over another? If I want to send a message to the app that the user has verified his email, which one should I choose?


Solution

  • Firebase Cloud Messaging sends messages to the app when after it is installed on the user's device. This can happen when the user is actively using the app, but also when they are not using the app. And these messages can either be displayed to the user (in which case they're referred to as notifications), or they can be handled silently.

    Firebase In-app Messaging creates configuration data at compile time that it includes in your app. It then monitors the Analytics events while the app runs, to determine when to display a message in the app. So: nothing is sent to the app here, all data is included in the app at build time.

    Since your use-case needs to send a message to the app after it's been installed, that would require the use of Firebase Cloud Messaging.