Help centre
Answer
What is the Background Sync API?
Short answer
The Background Sync API lets a service worker register a task that the browser retries automatically once the device is back online, even if the user has closed the tab. It is commonly used so a form submission or message made while offline is not lost — it queues, then fires the moment connectivity returns.
By InstantPWA engineering·Reviewed July 25, 2026
How it works
The page calls registration.sync.register("tag-name"); the service worker listens for a matching sync event, which the browser fires once the network is available.
Browser support
Supported in Chrome, Edge and other Chromium browsers. Safari and Firefox do not implement the One-off Background Sync API as of 2026.
Fallback
For unsupported browsers, apps typically fall back to retrying the request when the page next loads or via the online event.
Related
Do PWAs work offline?
PWAs can work offline, but only for content their service worker has explicitly cached. Registering a service worker does not automatically make a site offline-capable — you decide what to cache (app shell, API responses, images) and what strategy to use (cache-first, network-first, stale-while-revalidate).
What is Periodic Background Sync?
Periodic Background Sync lets an installed PWA periodically wake its service worker to refresh cached content — for example, prefetching news articles — even when the app is not open. It requires the periodic-background-sync permission, is only available on installed PWAs, and Chromium decides the actual interval based on site engagement, not the requested minimum.
What is the App Badging API?
The Badging API lets an installed PWA set a small numeric badge (or a plain dot) on its home-screen or taskbar icon, mirroring the unread-count badges native apps show. Call navigator.setAppBadge(count) to set it and navigator.clearAppBadge() to remove it — no argument shows a plain dot.
What is the Web Share API?
The Web Share API lets a page call navigator.share({ title, text, url }) to open the operating system’s native share sheet, so users can send a link to Messages, Mail, social apps or any other installed share target — the same experience as sharing from a native app.
What is the Web Share Target API?
The Web Share Target API lets an installed PWA declare a share_target entry in its manifest so it shows up in the device’s share sheet as a destination — the same way Twitter or Google Photos appear when you tap "Share" from another app. The declared URL receives the shared title, text, url or files as a request.