Setup guide · Nuxt
Turn a Nuxt 3 app into an installable PWA (2026)
Nuxt 3 PWA guide — manifest, service worker via @vite-pwa/nuxt, iOS install and hosted install popup.
Key takeaways
- @vite-pwa/nuxt generates the manifest and service worker for you.
- Register-type = autoUpdate keeps the worker in sync without user prompts.
- Nuxt does not solve iOS install — use InstantPWA or write a share-sheet card yourself.
Before you start
- Nuxt 3.6+
- @vite-pwa/nuxt
- HTTPS origin
manifest.webmanifest
{
"name": "Your product",
"short_name": "Product",
"start_url": "/",
"display": "standalone",
"background_color": "#ffffff",
"theme_color": "#111827",
"icons": [
{ "src": "/icon-192.png", "sizes": "192x192", "type": "image/png" },
{ "src": "/icon-512.png", "sizes": "512x512", "type": "image/png", "purpose": "any maskable" }
]
}Step-by-step for Nuxt
- Step 1Install the module
Run `pnpm add -D @vite-pwa/nuxt` and add it to modules in nuxt.config.ts.
- Step 2Configure the manifest
All PWA config lives under the `pwa` key in nuxt.config.ts. The module writes manifest.webmanifest and sw.js at build time.
export default defineNuxtConfig({ modules: ['@vite-pwa/nuxt'], pwa: { registerType: 'autoUpdate', manifest: { name: 'Your product', short_name: 'Product', theme_color: '#111827' }, }, }); - Step 3Add the install popup
Drop InstantPWA into app.vue for iOS + Chromium install UI.
<script src="https://instantpwa.com/api/public/embed.js?id=YOUR_ID" async></script>
Minimal sw.js
// public/sw.js
self.addEventListener('install', (e) => self.skipWaiting());
self.addEventListener('activate', (e) => self.clients.claim());
self.addEventListener('fetch', () => {});Common Nuxt gotchas
- In dev, set devOptions.enabled = true or the worker never registers.
- The module places sw.js at /sw.js — do not put a second service worker in /public or scopes will conflict.
FAQ
Do I need a native app if my Nuxt site is a PWA?
No. Once your Nuxt site meets the three PWA criteria (HTTPS, a manifest, a service worker), Chromium browsers offer to install it and iOS Safari 16.4+ supports the full standalone experience — including web push.
Will a service worker slow my Nuxt site down?
Not measurably on first load. The worker installs asynchronously after the page becomes interactive. On repeat visits it typically improves LCP and TTFB because assets are served from cache.
Can I still deploy my Nuxt site to Vercel, Netlify or Cloudflare?
Yes. Any static or edge host works — the manifest and service worker are plain files served from the origin. No build-time integration is required.
Skip the setup — drop in one line
InstantPWA handles the install prompt across iOS, Android and desktop. Free forever for one popup.
Get started free