As per this quote I found:
- registration_ids – Type String array – (Optional) [Recipients of a message] Multiple registration tokens, min 1 max 1000.
Is this the actual limit of device tokens I can send a single message to? And do messages to topics have the same limit?
ex:
{
"to": [reg_token_01, reg_token_02, ..., reg_token_1000],
"priority": "high",
"data": {
"title": "Hi Peeps!",
"message": "This is a special message for only for you... More details are available..."
}
}
As always, thanks for the info and direction!
You can send up to 240 messages/minute and 5,000 messages/hour to a single device.
Update: For v1, it seems that registration_ids
is no longer supported. It is strongly suggested that topics be used instead.
Seeing as FCM is based from the GCM core, the maximum number of registration tokens you can send to when using the registration_ids
parameter is 1000. I'm pretty sure you did see that in the official documentation.
So if ever you still intend to use the registration_ids
parameter but you need to send it to more than 1000, you can follow what was @Eran said in his answer here:
If you need to send the same message to more than 1000 Registration IDs, you simply split the sending process into groups of 1000 Registration IDs. Each group would be sent in a separate request to GCM server.
However, when it comes to topics, there is no limit. There used to be, but it was scrapped years ago. I have mentioned it my previous answers before:
Nope. As per their blog last December 2015:
We’re now happy to announce that we’re allowing unlimited free topics for your app. This means app developers can place an unlimited number of devices within each topic and create an unlimited number of topics.
Nope. Seeing that FCM has GCM as its core, there is no limit in the number of Topics for any app. There used to be a 1 million limit, but it was removed. You can refer to this Google Developers Blog for that.
Also, when creating a Topic in FCM, it would seem that it takes a day for it to be available, as per this post.
Apparently, there are legacy API's to achieve it. See here Send FCM message to multiple registration tokens
The method sendToDevice
accepts array of registration tokens
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With