Firebase Cloud Messaging: messaging/invalid-argument — Invalid registration token / payload
FCM rejected the message because the token or payload is malformed.
Invalid registration tokenThe registration token is not a valid FCM registration token Meaning
Data payload values must be strings, topics need the right format, and tokens must be real FCM registration tokens (not APNs tokens).
Common causes
- APNs token used instead of FCM token
- Data payload contains non-string values
- Payload over 4 KB
- Wrong topic name
⚡ Quick fix
- Use the FCM registration token
- Convert every
datavalue to a string - Trim the payload
Detailed fix by platform
Node.js
data: Object.fromEntries(Object.entries(obj).map(([k, v]) => [k, String(v)]))
How to diagnose
- Token — FCM token?
- Data — All strings?
- Size — Under 4 KB?
🔧 Still not fixed?
Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:
Similar errors
Most viewed in API
Other ways to find it
Where this error sits
Origin: Application & API. Errors that are often confused with or caused by this one (click to open):
🧠 Still stuck? Analyze your error
Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.
💬 What worked for others
No tips yet — did something else fix this for you?
Share what worked for you
Tips are checked by an editor before they appear. Links are removed.
Report a correction or suggest an improvement
Last updated 28 Nov 2026