---
source_url: https://www.pubnub.com/docs/integrations/mobile-push-notifications/check-fcm-payload
title: Check the FCM payload
updated_at: 2026-09-30T07:20:08.000Z
---

# Check the FCM payload

## Documentation index

To discover more PubNub resources:

1. Fetch [PubNub's llms.txt](https://www.pubnub.com/llms-full.txt) for a list of available pages in Markdown format.
2. Identify relevant URLs from that index.
3. Fetch the target pages.

Do not assume a path exists, always check the index first.

This guide shows you how to fix an FCM push notification that [Mobile Push Notifications](https://www.pubnub.com/docs/integrations/mobile-push-notifications/overview.md) delivers successfully but that doesn't display or behave as expected on an Android device. It covers only the `pn_fcm` block of your push payload. For a delivery failure on iOS, see [Send push notifications on iOS](https://www.pubnub.com/docs/integrations/mobile-push-notifications/send-push-notifications-ios.md) instead.

## Match the FCM message type to what your app expects

[Firebase Cloud Messaging (FCM)](https://firebase.google.com/docs/cloud-messaging/concept-options) supports notification and data messages. Use the message type that matches whether FCM or your app displays the alert.

```json
{
  "pn_fcm": {
    "notification": {
      "title": "Portugal vs Denmark",
      "body": "great match!"
    },
    "data": {
      "room": "Portugal vs Denmark",
      "body": "great match!"
    }
  }
}
```

Set `notification` in your `pn_fcm` payload if you want Android to display the alert automatically, with no app code involved.

Set `data` in your `pn_fcm` payload if your app needs to handle the push itself, such as updating UI state rather than only showing an alert. Your code, not the FCM SDK, is then responsible for displaying anything visible to the user.

Set both `notification` and `data` if you want Android to display the alert automatically **and** deliver custom data to your running app at the same time.

## Check the payload against the size limit

Keep your combined `notification` and `data` payload under the FCM limit.

| Item | Limit |
| --- | --- |
| Push credentials per keyset | 1 APNs certificate and 1 FCM key |
| Push notification payload size | 2 KB for APNs, 4 KB for FCM |

## Related tasks

* [Debug push notification messages](https://www.pubnub.com/docs/integrations/mobile-push-notifications/debug-push-notification-messages.md). Trace a push through the `-pndebug` channel when PubNub itself may be rejecting or dropping it.
* [Forward push errors and device removals to your endpoint](https://www.pubnub.com/docs/integrations/mobile-push-notifications/set-up-push-webhooks.md). Send push errors and device-removal events to your endpoint.
* [Check push device registration](https://www.pubnub.com/docs/integrations/mobile-push-notifications/check-push-device-registration.md). Confirm PubNub still has a valid device token registered for the channel.
* [Test mobile push notifications externally](https://www.pubnub.com/docs/integrations/mobile-push-notifications/test-mobile-push-notifications-externally.md). Send a push directly to FCM to rule out PubNub-side configuration.
* [Send push notifications on Android](https://www.pubnub.com/docs/integrations/mobile-push-notifications/send-push-notifications-android.md). Set up FCM push sending from your PubNub keyset.
* [Mobile push notifications](https://www.pubnub.com/docs/integrations/mobile-push-notifications/overview.md). How Mobile Push Notifications bridges PubNub pub/sub with APNs and FCM.
* [API limits](https://www.pubnub.com/docs/architecture/limits.md#mobile-push). Push credential and payload size limits.

Last updated at: 2026-09-30T07:20:08.000Z
