Push Notification - Notification icon not displaying using firebase

Hi all,

We were successfully able to test push notification, so this is a good move for us. However during our tesst, we observed that the icon in the notification status bar was a grey/white square.

See screenshot below:

According to one of the response from a web search (android - Grey square as notification icon using Firebase notifications - Stack Overflow) , it could potentialy be a problem inside the App.

Could you please confirm this is an actual issue? or tell me the current workaround?

It’s not related to Firebase. Starting with Android 3.0 status icons were revised, and “are composed simply of white pixels on a transparent backdrop, with alpha blending used for smooth edges and internal texture where appropriate” Icons – Material Design 3. From what I’ve seen, starting Android 5.0 you are forced to provide these all white small status icons otherwise the gray square icon shows up.`

This question Icon not displaying in notification: white square shown instead has answers that explain further and also show how to force your app to use the original ic_launcher icon although that doesn’t seem like a good idea to me since you are forcing it to target an older sdk and also not following material design guidelines.

What you really should do is provide the small white icons which you can generate here Android Asset Studio - Notification icon generator add them to your project and then configure FCM to use them as explained in the accepted answer

```
<meta-data
    android:name="com.google.firebase.messaging.default_notification_icon"
    android:resource="@drawable/ic_stat_ic_notification" />
<meta-data
    android:name="com.google.firebase.messaging.default_notification_color"
    android:resource="@color/colorAccent" />
```

Thanks,

Francoz

Not sure - when we send push notifications it has been a picture of the app’s logo in the status bar.

Which version of SAB are you using?

We are using 5.1 on a Mac and the test was done on a Nexus 5X Android 8.1