Nuxt: Failed to fetch dynamically imported module (after deploy) Vue Origin: On your device OSI layer 7 · Application Last updated 5 Nov 2026

Nuxt: [nuxt] error caught during app initialization TypeError: Failed to fetch dynamically imported module / Loading chunk failed

A browser tab running the old build requests chunk files that were replaced by a new deployment.

Exact message you may see [nuxt] error caught during app initialization TypeError: Failed to fetch dynamically imported moduleNuxt Failed to fetch dynamically imported module after deployChunkLoadError: Loading chunk failed NuxtLoading chunk failed. (missing: https://example.com/_nuxt/xyz.js)[nuxt] Error loading chunk
Seen on: Vue

Meaning

Nuxt can auto-reload on chunk errors (experimental.emitRouteChunkError: "automatic" in Nuxt 3, default in newer versions). Keep old assets on the CDN for some time, set cache headers (immutable for hashed assets, no-cache for HTML), and use zero-downtime deploys.

Common causes

  • Hashed chunks replaced by a deploy
  • CDN/HTML cached while chunks changed
  • Server rolling deploy serving mixed versions
  • Offline/network blocks
  • Wrong app.baseURL/cdnURL

⚡ Quick fix

  1. experimental: { emitRouteChunkError: "automatic" }
  2. Keep previous build assets available
  3. Cache HTML shortly and assets long (hashed)

Detailed fix by platform

Nuxt

  1. export default defineNuxtConfig({ experimental: { emitRouteChunkError: "automatic" } });

How to diagnose

  1. Deploy — Chunks removed?
  2. Cache — HTML stale?
  3. Config — Auto reload?

🔧 Still not fixed?

Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:

Where this error sits

Origin: On your device. Errors that are often confused with or caused by this one (click to open):

[vuex] unknown mutation type / unknown action type — Vuex: [vuex] unknown mutation type: SET_USER / [vuex] unknown action type: fetchUser (Vue)[vuex] unknown mutati…404 on page refresh (history mode) — Browser: Cannot GET /users/42 — refreshing a Vue Router history-mode page returns 404 (Vue)404 on page refresh (…ChunkLoadError — ChunkLoadError: Loading chunk 123 failed. (JavaScript)ChunkLoadErrorCould not find a production build in the '.next' directory — Next.js: Error: Could not find a production build in the '.next' directory. Try building your app with 'next build' before starting the production server (Next.js)Could not find a prod…Error: [vuex] do not mutate vuex store state outside mutation handlers — Vuex (strict mode): Error: [vuex] do not mutate vuex store state outside mutation handlers. (Vue)Error: [vuex] do not …Failed to fetch dynamically imported module / async component failed — Vue: TypeError: Failed to fetch dynamically imported module: https://app.example.com/assets/Settings-abc123.js (Vue)Failed to fetch dynam…Failed to find Server Action — Next.js: Error: Failed to find Server Action "abc123". This request might be from an older or newer deployment (Next.js)Failed to find Server…MIME type not executable — Refused to execute script from 'x' because its MIME type ('text/html') is not executable (JavaScript)MIME type not executa…Nuxt: Fai…

Explore the map of this error Full error map →

🧠 Still stuck? Analyze your error

Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.

💬 What worked for others

No tips yet — did something else fix this for you?

Share what worked for you

Tips are checked by an editor before they appear. Links are removed.