offline-fallback
Installation
SKILL.md
Provide an offline fallback page
The browser's default offline error screen ("No internet connection") is confusing and completely outside your brand. A custom offline page maintains the user experience, reinforces trust, and can surface cached content or useful actions — such as enabling users to continue reading a cached article or queuing a form submission for later.
Quick Reference
- Create a minimal /offline HTML page that works without any network requests
- Pre-cache the offline page during the service worker install event
- Intercept failed navigation requests and serve the offline page instead
- Include helpful guidance so users know what to do while offline
Check
Check whether the site shows a custom offline fallback page when the network is disconnected and a navigation request cannot be fulfilled.
Fix
Create a self-contained /offline page and configure the service worker to pre-cache it and serve it for failed navigation requests.