Push notification not working

I have configured push notification in app, by adding FCM key into it, but notification are not coming

Hello @aksh0377
Can you please share with us the steps you have followed to set up the push notifications and also share with us the code snippet for subscribing to push notifications at the client end.
So, can you please test if you are receiving the push notifications when sent via the firebase console

Awaiting reply

we have used below link as reference,
We get message when we test it from firebase dashboard but do not get from the chat.

Hi @aksh0377,

To receiver messages as push notification, you need to use onMessageRecieved(RemoteMessage remoteMessage) in your 'MyFirebaseMessagingService.java` and create a notification for each message you received.

Please refer the below MyFirebaseMessagingService.java

Also, make sure to add the MyFirebaseMessagingService.java as a service in your AndroidManifest File. So it will work in the background as well

        <action android:name="com.google.firebase.MESSAGING_EVENT" />
1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.