Yes, web push can update the app icon badge, but only for installed web apps. When a push event arrives, your service worker can call navigator.setAppBadge() to show a count or a dot on the icon. It works in desktop Chrome and Edge, and in Safari web apps on iOS 16.4+ and macOS. Firefox doesn’t.
I like the Badging API because it solves a real annoyance. Not every update deserves a banner that interrupts someone, yet people still want to know that something changed. A small “3” on an app icon does that quietly. Here’s how the web push app badge works, where it’s supported, and the limits I check before recommending it.
Key facts at a glance:
- API: the Badging API adds navigator.setAppBadge() and navigator.clearAppBadge(), and both work inside a service worker.
- Install required: badges appear on the icon of an installed web app (PWA), not on a normal browser tab.
- Chrome and Edge: supported on Windows and macOS since version 81, according to Chrome’s Badging API guide.
- Android: the API isn’t supported; Android shows a dot automatically while a notification is unread.
- Apple: Home Screen web apps on iOS and iPadOS 16.4+ support it, per WebKit’s announcement, and so do web apps on macOS Sonoma.
What is a web push app badge?
A web push app badge is the small dot or number on an installed web app’s icon, set by your code when a push message arrives. It’s the same badge you see on mail or chat apps, but driven by the Badging API instead of native code.
There are two badge types in the spec. App badges sit on the icon in the dock, taskbar, shelf or Home Screen. Document badges would sit on a browser tab, but browsers mostly don’t show those today. So in practice, this is an installed-app feature.
A badge can hold one of three states:
| State | How you set it | What users see |
|---|---|---|
| Nothing | clearAppBadge() or setAppBadge(0) | No badge |
| Flag | setAppBadge() with no number | A plain dot or marker |
| Number | setAppBadge(5) | A count, which the OS may cap (for example “99+”) |
Which browsers support the Badging API?
Chromium browsers on desktop and Safari support it for installed web apps; Firefox and Android Chrome don’t. That split matters, because many sites assume a badge will show everywhere and then wonder why Android users never see a count.
| Platform | Browser | App badge support (checked November 2026) |
|---|---|---|
| Windows, macOS | Chrome, Edge 81+ | Yes, for installed web apps |
| ChromeOS | Chrome | Listed as in development in Chrome’s guide |
| Android | Chrome | No API; the OS shows a dot while a notification is unread |
| iPhone, iPad | Safari Home Screen web apps, iOS 16.4+ | Yes, once notification permission is granted |
| macOS Sonoma+ | Safari web apps (Add to Dock) | Yes |
| Any | Firefox | No |
On iPhone and iPad, WebKit says setAppBadge() changes the count even before permission is granted. However, the badge only becomes visible once the user allows notifications for that Home Screen app. So the usual iPhone rules apply here too. My guide on getting web push working on iPhone covers them step by step.
How do you set the badge from a push event?
You set the badge inside the service worker’s push handler, right before or after you show the notification. Read the unread count from the payload, call setAppBadge(), and show the notification in the same event.
Here’s a minimal example:
self.addEventListener('push', (event) => {
const data = event.data ? event.data.json() : {};
const tasks = [
self.registration.showNotification(data.title || 'New update', {
body: data.body,
icon: '/icon-192.png',
data: { url: data.url }
})
];
if ('setAppBadge' in navigator) {
tasks.push(navigator.setAppBadge(data.unread || 0));
}
event.waitUntil(Promise.all(tasks));
});A few things make this reliable:
- Send the full count in the payload, such as “unread”: 4, rather than “add one”. Messages can arrive late or out of order.
- Feature-detect with ‘setAppBadge’ in navigator, so unsupported browsers skip it silently.
- Wrap everything in event.waitUntil(), so the worker stays alive until both steps finish.
- Clear the badge when the user opens the app or reads the items, using navigator.clearAppBadge().
If you’re new to the push handler itself, my walkthrough of the service worker for web push explains each event.
Can you update the badge without showing a notification?
Usually no. Chrome requires a visible notification for every push message, so you can’t use web push to change the badge silently. Chrome’s guide says this directly: a push can update the badge, but it must also display a notification.
Safari has the same rule. Each push must show a notification, and repeated silent pushes can cost you the subscription. I explain why in my post on silent web push notifications.
So what can you do for low-priority count updates? Chrome suggests a mix:
- Push for important events: show a notification and update the badge together.
- Page open: update the badge from the page whenever the app is in use.
- Periodic Background Sync: let Chrome poll your server now and then, at a frequency the browser decides.
How does Declarative Web Push handle badges?
Declarative Web Push includes an app badge field in the JSON payload, so Safari can set the badge without running your service worker. You send the title, body, link and badge number as structured JSON, and the browser shows the notification and badge itself.
This is newer and Safari-led, so keep a service worker fallback for other browsers. I covered the format and current support in what Declarative Web Push is.
When is an app badge worth using?
An app badge is worth it when your product has a count that people care about. Inboxes, chats, task lists, order queues and support tickets all fit. A content site with no unread concept usually doesn’t need one.
| Use case | Badge makes sense? | Why |
|---|---|---|
| Chat or inbox web app | Yes | Unread count is the main signal |
| Task or project tool | Yes | Pending items need attention |
| Store with order tracking | Sometimes | Useful for open orders, not promotions |
| News or blog site | Rarely | Visitors rarely install it, and there’s no unread state |
That said, the badge only helps if people install your app. Most blog readers subscribe to push in the browser and never install anything. For them, the notification itself is the signal, and a badge adds nothing. My guide to PWA push notifications explains when installing makes sense.
What mistakes stop the badge from showing?
The badge usually fails for simple reasons: the app isn’t installed, the browser doesn’t support the API, or the count is zero. Check these before debugging your code.
- Not installed: in Chrome, the site must be installed as a web app and opened from its own window.
- Wrong platform: Android Chrome and Firefox ignore the API.
- No permission on Apple devices: the count is stored, but nothing shows until notifications are allowed.
- Zero sent: setAppBadge(0) clears the badge, so a missing field can wipe it.
- OS settings: users can turn off badges per app in system settings.
You can watch push events and badge calls in Chrome DevTools. My guide to debugging web push in Chrome DevTools shows where to look.
Where LaraPush fits
LaraPush is a self-hosted web push panel that you install on your own VPS, for a one-time licence from $499 (check LaraPush pricing for current prices). It focuses on sending notifications: campaigns, segmentation, automation and analytics, as listed on the features page. App badges are a separate, client-side feature, so you’d add setAppBadge() to your own web app if you need it. The trade-offs are no free plan, a licence that covers one server, and a VPS you maintain. For a wider view of tools, see my list of the best push notification services.
Frequently asked questions
In Chrome and Edge on desktop, the Badging API itself doesn’t need permission, but the app must be installed. However, updating the badge from a push message needs push permission. On iPhone, iPad and Mac Safari web apps, the badge only shows after the user allows notifications.
Android Chrome doesn’t support the Badging API. Instead, Android shows a dot on the installed web app’s icon automatically while a notification from that app is unread. You can’t set a number yourself, and the dot clears when the notification is dismissed.
Not in practice. The spec describes document badges for tabs, but browsers mainly support app badges on installed web apps. For a regular tab, sites still change the title or favicon to show an unread count.
Yes. The Badging API is available on WorkerNavigator, so you can call navigator.setAppBadge() in the service worker’s push handler. Wrap the call in event.waitUntil() together with showNotification(), so the worker stays alive until both finish.
Call navigator.clearAppBadge() from the page when the user opens the relevant screen, or setAppBadge(0). You can also clear it in the service worker’s notificationclick handler, then send fresh counts in later push payloads so the badge stays accurate.




