[GH-ISSUE #70] Consider setting FCM priority to "high" for better delivery #59

Closed
opened 2026-05-07 00:19:21 +02:00 by BreizhHardware · 5 comments

Originally created by @abrender on GitHub (Dec 29, 2021).
Original GitHub issue: https://github.com/binwiederhier/ntfy/issues/70

I noticed that Instant Delivery is recommended for instant alerts because "Without instant delivery, messages may arrive with a significant delay".

A bit of snooping reveals that you can set the priority of a message to "high", which will "allow FCM to wake up a sleeping device when necessary". That functionality appears to be limited/bucketted but "if, in response to a high priority message, a notification is displayed in a way that is visible to the user, then your app standby bucket quota will not be consumed by that message".

Originally created by @abrender on GitHub (Dec 29, 2021). Original GitHub issue: https://github.com/binwiederhier/ntfy/issues/70 I noticed that [Instant Delivery](https://ntfy.sh/docs/subscribe/phone/#instant-delivery) is recommended for instant alerts because "Without instant delivery, messages may arrive with a significant delay". A bit of snooping reveals that you can [set the priority of a message to "high"](https://firebase.google.com/docs/cloud-messaging/concept-options#setting-the-priority-of-a-message), which will "allow FCM to wake up a sleeping device when necessary". That functionality appears to be limited/bucketted but "if, in response to a high priority message, a notification is displayed in a way that is visible to the user, then your app standby bucket quota will not be consumed by that message".
BreizhHardware 2026-05-07 00:19:21 +02:00
Author
Owner

@binwiederhier commented on GitHub (Dec 29, 2021):

Thank you for the suggestion. I remember seeing it, but there was some comment about not misusing it, or otherwise there will be some penalty. I forgot, but I'll read up on it again.

<!-- gh-comment-id:1002451822 --> @binwiederhier commented on GitHub (Dec 29, 2021): Thank you for the suggestion. I remember seeing it, but there was some comment about not misusing it, or otherwise there will be some penalty. I forgot, but I'll read up on it again.
Author
Owner

@binwiederhier commented on GitHub (Dec 29, 2021):

Ah yes it's right there

High priority messages generally should result in user interaction with your app or its notifications. If FCM detects a pattern in which they don't, your messages may be de-prioritized.

<!-- gh-comment-id:1002452327 --> @binwiederhier commented on GitHub (Dec 29, 2021): Ah yes it's right there > High priority messages generally should result in user interaction with your app or its notifications. If FCM detects a pattern in which they don't, your messages may be de-prioritized.
Author
Owner

@binwiederhier commented on GitHub (Dec 29, 2021):

if, in response to a high priority message, a notification is displayed in a way that is visible to the user, then your app standby bucket quota will not be consumed by that message

wait so do you think this means that if i display a notificaiton visible to the user, then the de-prioritization won't happen?

<!-- gh-comment-id:1002620200 --> @binwiederhier commented on GitHub (Dec 29, 2021): > if, in response to a high priority message, a notification is displayed in a way that is visible to the user, then your app standby bucket quota will not be consumed by that message wait so do you think this means that if i display a notificaiton visible to the user, then the de-prioritization won't happen?
Author
Owner

@binwiederhier commented on GitHub (Dec 31, 2021):

I think it may be worth setting the FCM priority to high for ntfy priorities 4 and 5, but I think I may need to create a limiter to regulate how often it's used. I will have to do some more research.

<!-- gh-comment-id:1003367216 --> @binwiederhier commented on GitHub (Dec 31, 2021): I think it may be worth setting the FCM priority to high for ntfy priorities 4 and 5, but I think I may need to create a limiter to regulate how often it's used. I will have to do some more research.
Author
Owner

@binwiederhier commented on GitHub (Jan 4, 2022):

@abrender With the next server release, messages with priority 4+5 (high+max) will be FCM high priority messages

<!-- gh-comment-id:1005136997 --> @binwiederhier commented on GitHub (Jan 4, 2022): @abrender With the next server release, messages with priority 4+5 (high+max) will be FCM high priority messages
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/ntfy#59
No description provided.