Nuxt 4.3 brings powerful new features for layouts, caching, and developer experience – plus significant performance improvements under the hood.
📣 Some News
Extended v3 Support
Early this month, I opened a discussion to find out how the upgrade had gone from v3 to v4. I was really pleased to hear how well it had gone for most people.
Having said that, we're committed to making sure no one gets left behind. And so we will continue to provide security updates and critical bug fix releases beyond the previously announced end-of-life date of January 31, 2026, meaning Nuxt v3 will meet its end-of-life on July 31, 2026.
[!TIP]
As usual, today also brings a minor release for v3, with many of the same improvements backported from v4.3.
Preparing for Nuxt 5
We're closer than ever to the releases of Nuxt v5 and Nitro v3. In the coming weeks, the main branch of the Nuxt repository will begin receiving initial commits for Nuxt 5. However, it's still business as usual.
Continue making pull requests to the main branch
We'll backport changes to the 4.x and 3.x branches
Keep an eye out on the Upgrade Guide – we'll be adding details about how you can already start migrating your projects to prepare for Nuxt v4 with future.compatibilityVersion: 5.
🗂️ Route Rule Layouts
But that's enough about the future. We have a lot of good things for you today!
First, you can now set layouts directly in route rules using the new appLayout property (#31092). This provides a centralized, declarative way to manage layouts across your application without scattering definePageMeta calls throughout your pages.
Payload extraction now works with ISR (incremental static regeneration), SWR (stale-while-revalidate) and cache routeRules (#33467). Previously, only pre-rendered pages could generate _payload.json files.
This means:
Client-side navigation to ISR/SWR pages can use cached payloads
CDNs (Vercel, Netlify, Cloudflare) can cache payload files alongside HTML
Fewer API calls during navigation – data can be prefetched and served from the cached payload
exportdefaultdefineNuxtConfig({routeRules:{'/products/**':{isr: 3600,// Revalidate every hour
}}})
🧹 Dev Mode Payload Extraction
Related to the above, payload extraction now also works in development mode (#30784). This makes it easier to test and debug payload behavior without needing to run a production build.
[!IMPORTANT]
Payload extraction works in dev mode with nitro.static set to true, or for individual pages which have isr, swr, prerender or cache route rules.
🚫 Disable Modules from Layers
When extending Nuxt layers, you can now disable specific modules that you don't need (#33883). Just pass false to the module's options:
exportdefaultdefineNuxtConfig({extends:['../shared-layer'],// disable @​nuxt/image from layer
image: false,})
🏷️ Route Groups in Page Meta
Route groups (folders wrapped in parentheses like (protected)/) are now exposed in page meta (#33460). This makes it easy to check which groups a route belongs to in middleware or anywhere you have access to the route.
<scriptsetuplang="ts">// This page's meta will include: { groups: ['protected'] }
useRoute().meta.groups</script>
Module authors can now use async functions when adding build plugins (#33619):
exportdefaultdefineNuxtModule({asyncsetup() {// Lazy load only when actually needed
addVitePlugin(()=>import('my-cool-plugin').then(r=>r.default()))// No need to load webpack plugin if using Vite
addWebpackPlugin(()=>import('my-cool-plugin/webpack').then(r=>r.default()))}})
This enables true lazy loading of build plugins, avoiding unnecessary code loading when plugins aren't needed.
🚀 Performance Improvements
This release includes several performance optimizations for faster builds:
Hook filters - Internal plugins now use filters to avoid running hooks unnecessarily (#33898)
SSR styles optimization - The nuxt:ssr-styles plugin is now significantly faster (#33862, #33865)
Layer alias transform - Skipped when using Vite (it handles this natively) (#33864)
Route rules compilation - Route rules are now compiled into a client chunk using rou3, removing the need for radix3 in the client bundle and eliminating app manifest fetches (#33920)
🎨 Inline Styles for Webpack/Rspack
The inlineStyles feature now works with webpack and rspack builders (#33966), not just Vite. This enables critical CSS inlining for better Core Web Vitals regardless of your bundler choice.
⚠️ Deprecations
statusCode → status, statusMessage → statusText
In preparation for Nitro v3 and H3 v2, we're moving to use Web API naming conventions (#33912). The old properties still work but are deprecated in advance of v5:
Enabled allowArbitraryExtensions by default in TypeScript config (#34084)
Added noUncheckedIndexedAccess to server tsconfig for safer typing (#33985)
[!IMPORTANT]
Enabling noUncheckedIndexedAccess in the Nitro server TypeScript config improves type safety but may surface new type errors in your server code. This change was necessary because Nuxt's app context performs type checks on server routes (learn more).
While we recommend keeping this enabled for better type safety, you can disable it if needed:
Clarified type-checking context limitations for server routes (#33964)
🎉 Nuxt 3.21.0
Alongside v4.3.0, we're releasing Nuxt v3.21.0 with many of the same improvements backported to the 3.x branch. This release includes:
All the same features: Route rule layouts, ISR payload extraction, layout props with setPageLayout, #server alias, draggable error overlay, and more
All performance improvements: SSR styles optimization, hook filters, and route rules compilation
Module disabling: Disable layer modules by setting options to false
Critical bug fixes: Async data reactivity in Options API, useCookie number parsing, head component deduplication, and more
✅ Upgrading
Our recommendation for upgrading is to run:
npx nuxt upgrade --dedupe
# or, if you are upgrading to v3.21
npx nuxt@latest upgrade --dedupe --channel=v3
This will deduplicate your lockfile and help ensure you pull in updates from other dependencies that Nuxt relies on, particularly in the unjs ecosystem.
[!TIP]
Check out our upgrade guide if upgrading from an older version.
This PR contains the following updates:
| Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) |
|---|---|---|---|
| [nuxt](https://nuxt.com) ([source](https://github.com/nuxt/nuxt/tree/HEAD/packages/nuxt)) | [`4.2.2` → `4.3.0`](https://renovatebot.com/diffs/npm/nuxt/4.2.2/4.3.0) |  |  |
---
### Release Notes
<details>
<summary>nuxt/nuxt (nuxt)</summary>
### [`v4.3.0`](https://github.com/nuxt/nuxt/releases/tag/v4.3.0)
[Compare Source](https://github.com/nuxt/nuxt/compare/v4.2.2...v4.3.0)
> 4.3.0 is the next minor release.
Nuxt 4.3 brings powerful new features for layouts, caching, and developer experience – plus significant performance improvements under the hood.
#### 📣 Some News
##### Extended v3 Support
Early this month, I [opened a discussion](https://github.com/nuxt/nuxt/discussions/33918) to find out how the upgrade had gone from v3 to v4. I was really pleased to hear how well it had gone for most people.
Having said that, we're committed to making sure no one gets left behind. And so we will **continue to provide security updates and critical bug fix releases** beyond the previously announced end-of-life date of January 31, 2026, meaning Nuxt v3 will meet its end-of-life on July 31, 2026.
> \[!TIP]
> As usual, today also brings a minor release for v3, with many of the same improvements backported from v4.3.
##### Preparing for Nuxt 5
We're closer than ever to the releases of Nuxt v5 and Nitro v3. In the coming weeks, the `main` branch of the Nuxt repository will begin receiving initial commits for Nuxt 5. However, it's still **business as usual**.
- Continue making pull requests to the `main` branch
- We'll backport changes to the `4.x` and `3.x` branches
Keep an eye out on the [Upgrade Guide](/docs/4.x/getting-started/upgrade) – we'll be adding details about how you can already start migrating your projects to prepare for Nuxt v4 with `future.compatibilityVersion: 5`.
#### 🗂️ Route Rule Layouts
But that's enough about the future. We have a lot of good things for you today!
First, you can now set layouts directly in route rules using the new `appLayout` property ([#​31092](https://github.com/nuxt/nuxt/pull/31092)). This provides a centralized, declarative way to manage layouts across your application without scattering `definePageMeta` calls throughout your pages.
```ts [nuxt.config.ts]
export default defineNuxtConfig({
routeRules: {
'/admin/**': { appLayout: 'admin' },
'/dashboard/**': { appLayout: 'dashboard' },
'/auth/**': { appLayout: 'minimal' }
}
})
```
This might be useful for:
- Admin panels with a shared layout across many routes
- Marketing pages that need a different layout from the app
> \[!TIP]
> Plus, you can pass props to layouts now! See [the `setPageLayout` improvements below](#layout-props-with-setpagelayout).
#### 📦 ISR/SWR Payload Extraction
Payload extraction now works with ISR (incremental static regeneration), SWR (stale-while-revalidate) and cache `routeRules` ([#​33467](https://github.com/nuxt/nuxt/pull/33467)). Previously, only pre-rendered pages could generate `_payload.json` files.
This means:
- Client-side navigation to ISR/SWR pages can use cached payloads
- CDNs (Vercel, Netlify, Cloudflare) can cache payload files alongside HTML
- Fewer API calls during navigation – data can be prefetched and served from the cached payload
```ts [nuxt.config.ts]
export default defineNuxtConfig({
routeRules: {
'/products/**': {
isr: 3600, // Revalidate every hour
}
}
})
```
#### 🧹 Dev Mode Payload Extraction
Related to the above, payload extraction now also works in development mode ([#​30784](https://github.com/nuxt/nuxt/pull/30784)). This makes it easier to test and debug payload behavior without needing to run a production build.
> \[!IMPORTANT]
> Payload extraction works in dev mode with `nitro.static` set to `true`, or for individual pages which have `isr`, `swr`, `prerender` or `cache` route rules.
#### 🚫 Disable Modules from Layers
When extending Nuxt layers, you can now disable specific modules that you don't need ([#​33883](https://github.com/nuxt/nuxt/pull/33883)). Just pass `false` to the module's options:
```ts [nuxt.config.ts]
export default defineNuxtConfig({
extends: ['../shared-layer'],
// disable @​nuxt/image from layer
image: false,
})
```
#### 🏷️ Route Groups in Page Meta
[Route groups](/docs/4.x/directory-structure/app/pages#route-groups) (folders wrapped in parentheses like `(protected)/`) are now exposed in page meta ([#​33460](https://github.com/nuxt/nuxt/pull/33460)). This makes it easy to check which groups a route belongs to in middleware or anywhere you have access to the route.
```vue [pages/(protected)/dashboard.vue]
<script setup lang="ts">
// This page's meta will include: { groups: ['protected'] }
useRoute().meta.groups
</script>
```
```ts [middleware/auth.ts]
export default defineNuxtRouteMiddleware((to) => {
if (to.meta.groups?.includes('protected') && !isAuthenticated()) {
return navigateTo('/login')
}
})
```
This provides a clean, convention-based approach to route-level authorization without needing to add `definePageMeta` to every protected page.
#### 🎨 Layout Props with `setPageLayout`
The `setPageLayout` composable now accepts a second parameter to pass props to your layout ([#​33805](https://github.com/nuxt/nuxt/pull/33805)):
```ts [middleware/admin.ts]
export default defineNuxtRouteMiddleware((to) => {
setPageLayout('admin', {
sidebar: true,
theme: 'dark'
})
})
```
```vue [layouts/admin.vue]
<script setup lang="ts">
defineProps<{
sidebar?: boolean
theme?: 'light' | 'dark'
}>()
</script>
```
#### 🔧 `#server` Alias
A new `#server` alias provides clean imports within your server directory ([#​33870](https://github.com/nuxt/nuxt/pull/33870)), similar to how `#shared` works:
```ts [server/api/users/[id]/profile.ts]
// Before: relative path hell
import { helper } from '../../../../utils/helper'
// After: clean and predictable
import { helper } from '#server/utils/helper'
```
The alias includes import protection – you can't accidentally import `#server` code from client or shared contexts.
#### 🪟 Draggable Error Overlay
The development error overlay introduced in Nuxt 4.2 is now draggable and can be minimized ([#​33695](https://github.com/nuxt/nuxt/pull/33695)). You can:
- Drag it to any corner of the screen (it snaps to edges)
- Minimize it to a small pill button when you want to keep working
- Your position and minimized state persist across page reloads
This is a quality-of-life improvement when you're iterating on fixes and don't want the overlay blocking your view.
<https://github.com/user-attachments/assets/nuxt_4-3_error_demo.mp4>
#### ⚙️ Async Plugin Constructors
Module authors can now use async functions when adding build plugins ([#​33619](https://github.com/nuxt/nuxt/pull/33619)):
```ts [modules/my-module.ts]
export default defineNuxtModule({
async setup() {
// Lazy load only when actually needed
addVitePlugin(() => import('my-cool-plugin').then(r => r.default()))
// No need to load webpack plugin if using Vite
addWebpackPlugin(() => import('my-cool-plugin/webpack').then(r => r.default()))
}
})
```
This enables true lazy loading of build plugins, avoiding unnecessary code loading when plugins aren't needed.
#### 🚀 Performance Improvements
This release includes several performance optimizations for faster builds:
- **Hook filters** - Internal plugins now use filters to avoid running hooks unnecessarily ([#​33898](https://github.com/nuxt/nuxt/pull/33898))
- **SSR styles optimization** - The `nuxt:ssr-styles` plugin is now significantly faster ([#​33862](https://github.com/nuxt/nuxt/pull/33862), [#​33865](https://github.com/nuxt/nuxt/pull/33865))
- **Layer alias transform** - Skipped when using Vite (it handles this natively) ([#​33864](https://github.com/nuxt/nuxt/pull/33864))
- **Route rules compilation** - Route rules are now compiled into a client chunk using `rou3`, removing the need for `radix3` in the client bundle and eliminating app manifest fetches ([#​33920](https://github.com/nuxt/nuxt/pull/33920))
#### 🎨 Inline Styles for Webpack/Rspack
The `inlineStyles` feature now works with webpack and rspack builders ([#​33966](https://github.com/nuxt/nuxt/pull/33966)), not just Vite. This enables critical CSS inlining for better Core Web Vitals regardless of your bundler choice.
#### ⚠️ Deprecations
##### `statusCode` → `status`, `statusMessage` → `statusText`
In preparation for Nitro v3 and H3 v2, we're moving to use Web API naming conventions ([#​33912](https://github.com/nuxt/nuxt/pull/33912)). The old properties still work but are deprecated in advance of v5:
```diff
- throw createError({ statusCode: 404, statusMessage: 'Not Found' })
+ throw createError({ status: 404, statusText: 'Not Found' })
```
#### 🐛 Bug Fixes
Notable fixes in this release:
- Fixed head component deduplication using `key` attribute ([#​33958](https://github.com/nuxt/nuxt/pull/33958), [#​33963](https://github.com/nuxt/nuxt/pull/33963))
- Fixed async data properties not being reactive in Options API ([#​34119](https://github.com/nuxt/nuxt/pull/34119))
- Fixed `useCookie` unsafe number parsing during decode ([#​34007](https://github.com/nuxt/nuxt/pull/34007))
- Fixed `NuxtPage` not re-rendering when nested `NuxtLayout` has layouts disabled ([#​34078](https://github.com/nuxt/nuxt/pull/34078))
- Fixed client-side pathname decoding for non-ASCII route aliases ([#​34043](https://github.com/nuxt/nuxt/pull/34043))
- Fixed suspense remounting when navigating after pending state ([#​33991](https://github.com/nuxt/nuxt/pull/33991))
- Fixed clipboard copy in error overlay ([#​33873](https://github.com/nuxt/nuxt/pull/33873))
- Enabled `allowArbitraryExtensions` by default in TypeScript config ([#​34084](https://github.com/nuxt/nuxt/pull/34084))
- Added `noUncheckedIndexedAccess` to server tsconfig for safer typing ([#​33985](https://github.com/nuxt/nuxt/pull/33985))
> \[!IMPORTANT]
> Enabling `noUncheckedIndexedAccess` in the Nitro server TypeScript config improves type safety but may surface new type errors in your server code. This change was necessary because Nuxt's app context performs type checks on server routes ([learn more](https://nuxt.com/docs/4.x/guide/modules/recipes-advanced#known-limitations)).
>
> While we recommend keeping this enabled for better type safety, you can disable it if needed:
>
> ```ts
> export default defineNuxtConfig({
> nitro: {
> typescript: {
> tsConfig: {
> compilerOptions: {
> noUncheckedIndexedAccess: false
> }
> }
> }
> }
> })
> ```
>
> Note that disabling this may allow type errors to slip through that could cause runtime issues with indexed access.
#### 📚 Documentation
- Improved module author guides with clearer structure ([#​33803](https://github.com/nuxt/nuxt/pull/33803))
- Added MCP setup instructions for Claude Desktop ([#​33914](https://github.com/nuxt/nuxt/pull/33914))
- Added layers directory documentation ([#​33967](https://github.com/nuxt/nuxt/pull/33967))
- Added Deno package manager examples ([#​34070](https://github.com/nuxt/nuxt/pull/34070))
- Clarified type-checking context limitations for server routes ([#​33964](https://github.com/nuxt/nuxt/pull/33964))
#### 🎉 Nuxt 3.21.0
Alongside v4.3.0, we're releasing **Nuxt v3.21.0** with many of the same improvements backported to the 3.x branch. This release includes:
- **All the same features**: Route rule layouts, ISR payload extraction, layout props with `setPageLayout`, `#server` alias, draggable error overlay, and more
- **All performance improvements**: SSR styles optimization, hook filters, and route rules compilation
- **Module disabling**: Disable layer modules by setting options to `false`
- **Critical bug fixes**: Async data reactivity in Options API, `useCookie` number parsing, head component deduplication, and more
#### ✅ Upgrading
Our recommendation for upgrading is to run:
```sh
npx nuxt upgrade --dedupe
# or, if you are upgrading to v3.21
npx nuxt@latest upgrade --dedupe --channel=v3
```
This will deduplicate your lockfile and help ensure you pull in updates from other dependencies that Nuxt relies on, particularly in the unjs ecosystem.
> \[!TIP]
> Check out our [upgrade guide](/docs/getting-started/upgrade) if upgrading from an older version.
#### 👉 Changelog
[compare changes](https://github.com/nuxt/nuxt/compare/v4.2.2...v4.3.0)
##### 🚀 Enhancements
- **kit:** Support async constructor for adding plugins ([#​33619](https://github.com/nuxt/nuxt/pull/33619))
- **kit:** Export Nuxt major version type ([#​33700](https://github.com/nuxt/nuxt/pull/33700))
- **schema:** Add `#server` alias for server directory imports ([#​33870](https://github.com/nuxt/nuxt/pull/33870))
- **ui-templates:** Let it snow! ❄️ ([#​33804](https://github.com/nuxt/nuxt/pull/33804))
- **schema:** Hoist nitro `crossws` types ([5b16a51f5](https://github.com/nuxt/nuxt/commit/5b16a51f5))
- **nitro,nuxt:** Compile route rules into client chunk ([#​33920](https://github.com/nuxt/nuxt/pull/33920))
- **nuxt:** Allow disabling modules by setting module options to `false` ([#​33883](https://github.com/nuxt/nuxt/pull/33883))
- **kit:** Allow specifying `moduleDependencies` as an async function ([#​33504](https://github.com/nuxt/nuxt/pull/33504))
- **nuxt:** Support `appLayout` in route rules ([#​31092](https://github.com/nuxt/nuxt/pull/31092))
- **nuxt:** Add route groups to page meta ([#​33460](https://github.com/nuxt/nuxt/pull/33460))
- **nuxt:** Enable payload extraction for ISR/SWR routes ([#​33467](https://github.com/nuxt/nuxt/pull/33467))
- **nuxt:** Allow updating props with `setPageLayout` ([#​33805](https://github.com/nuxt/nuxt/pull/33805))
- **nuxt:** Enable dragging and minimizing for error overlay ([#​33695](https://github.com/nuxt/nuxt/pull/33695))
- **nitro,nuxt:** Add support for payload extraction in dev ([#​30784](https://github.com/nuxt/nuxt/pull/30784))
- **rspack,webpack:** Add inline styles ([#​33966](https://github.com/nuxt/nuxt/pull/33966))
- **kit:** Add forward-compatible nitro types ([#​34036](https://github.com/nuxt/nuxt/pull/34036))
##### 🔥 Performance
- **nuxt:** Do not init layer alias transform when using vite ([#​33864](https://github.com/nuxt/nuxt/pull/33864))
- **vite:** Add hook filters for ssr styles plugin ([#​33865](https://github.com/nuxt/nuxt/pull/33865))
- **vite:** Optimize `nuxt:ssr-styles` plugin ([#​33862](https://github.com/nuxt/nuxt/pull/33862))
- **nuxt:** Use filter for vfs plugin load ([eb3d2d4c6](https://github.com/nuxt/nuxt/commit/eb3d2d4c6))
- **nuxt,vite:** Use filters to avoid running hooks unnecessarily ([6b7fc7477](https://github.com/nuxt/nuxt/commit/6b7fc7477))
- **nuxt,vite:** Add more filters to internal plugins ([#​33898](https://github.com/nuxt/nuxt/pull/33898))
##### 🩹 Fixes
- **kit:** Normalize local layer paths with trailing slashes ([#​33858](https://github.com/nuxt/nuxt/pull/33858))
- **nuxt:** Avoid overwriting multiple head input in island handler ([#​33849](https://github.com/nuxt/nuxt/pull/33849))
- **nuxt:** Update meta instead of calling `router.replace` in page hmr ([#​33897](https://github.com/nuxt/nuxt/pull/33897))
- **nuxt:** Don't call `page:loading:end` in cache if already called ([7789f73bd](https://github.com/nuxt/nuxt/commit/7789f73bd))
- **vite:** Add error handling for parsing `NUXT_VITE_NODE_OPTIONS` ([41a564d23](https://github.com/nuxt/nuxt/commit/41a564d23))
- **nuxt:** Do not skip middleware when `appMiddleware` references invalid key ([323f27bc8](https://github.com/nuxt/nuxt/commit/323f27bc8))
- **nitro:** Clipboard copy in error overlay ([#​33873](https://github.com/nuxt/nuxt/pull/33873))
- **webpack,rspack:** Resolve deep imports in virtual files ([#​33927](https://github.com/nuxt/nuxt/pull/33927))
- **webpack:** Disable async chunks in dev mode ([0310c4070](https://github.com/nuxt/nuxt/commit/0310c4070))
- **webpack:** Correctly evaluate sourcemap name ([653f364af](https://github.com/nuxt/nuxt/commit/653f364af))
- **nuxt:** Handle node10 resolution for `nuxt/meta` ([01c2c9b13](https://github.com/nuxt/nuxt/commit/01c2c9b13))
- **nuxt:** Do not early return if component priorities conflict ([#​33955](https://github.com/nuxt/nuxt/pull/33955))
- **nuxt:** Use `key` for tag deduplication in `<Head>` component ([#​33958](https://github.com/nuxt/nuxt/pull/33958))
- **schema,vite:** Resolve `build.transpile` when initialising vite ([#​33868](https://github.com/nuxt/nuxt/pull/33868))
- **nuxt,rspack,webpack:** Inject module identifiers for webpack builders ([#​33962](https://github.com/nuxt/nuxt/pull/33962))
- **nuxt:** Add key to head components for proper deduplication ([#​33963](https://github.com/nuxt/nuxt/pull/33963))
- **nitro:** Check prettyResponse.body type before error overlay ([#​33977](https://github.com/nuxt/nuxt/pull/33977))
- **nuxt:** Don't URI-encode static route paths ([#​33990](https://github.com/nuxt/nuxt/pull/33990))
- **nuxt:** Skip internal stub routes from prerender ([#​34001](https://github.com/nuxt/nuxt/pull/34001))
- **kit,schema:** Align module `onUpgrade` arguments with types ([#​33988](https://github.com/nuxt/nuxt/pull/33988))
- **nuxt:** Handle unsafe number parsing in useCookie decode ([#​34007](https://github.com/nuxt/nuxt/pull/34007))
- **nuxt:** Do not externalise `rou3` ([2df4e1ae3](https://github.com/nuxt/nuxt/commit/2df4e1ae3))
- **nitro:** Add `noUncheckedIndexedAccess` to server tsconfig ([#​33985](https://github.com/nuxt/nuxt/pull/33985))
- **nuxt:** Add auto-import declarations for `shared/` context ([#​33978](https://github.com/nuxt/nuxt/pull/33978))
- **nuxt:** Update global reference to globalThis in `useRequestFetch` ([#​33976](https://github.com/nuxt/nuxt/pull/33976))
- **vite:** Configure hmr port for server build ([#​33929](https://github.com/nuxt/nuxt/pull/33929))
- **kit:** Add forward compatible nitro v3 types ([#​34053](https://github.com/nuxt/nuxt/pull/34053))
- **nitro,nuxt:** Do not import nitro deps in builders ([#​34054](https://github.com/nuxt/nuxt/pull/34054))
- **nitro:** Add `h3` types to auto-imports ([#​34035](https://github.com/nuxt/nuxt/pull/34035))
- **schema:** Add some more directories to ignore ([ebc2a66ab](https://github.com/nuxt/nuxt/commit/ebc2a66ab))
- **nitro:** Also augment `nuxt/schema` ([a6a044d81](https://github.com/nuxt/nuxt/commit/a6a044d81))
- **nuxt:** Make asyncData properties reactive in Options API ([#​34119](https://github.com/nuxt/nuxt/pull/34119))
- **nuxt:** Rerender `NuxtPage` when nested `NuxtLayout` has explicitly disabled layouts ([#​34078](https://github.com/nuxt/nuxt/pull/34078))
- **kit,nitro:** Enable `allowArbitraryExtensions` by default ([#​34084](https://github.com/nuxt/nuxt/pull/34084))
- **nuxt:** Decode client-side pathname for non-ASCII route aliases ([#​34043](https://github.com/nuxt/nuxt/pull/34043))
- **nuxt:** Force remount suspense when navigating after pending ([#​33991](https://github.com/nuxt/nuxt/pull/33991))
- **nuxt:** Add documentation link to server builder error message ([#​34122](https://github.com/nuxt/nuxt/pull/34122))
- **nuxt:** Validate placeholder/fallback tags + warn about placeholder/fallback props ([567a1c6fb](https://github.com/nuxt/nuxt/commit/567a1c6fb))
- **nuxt:** Force flush `useAsyncData` debounced execute post watcher flush ([#​34125](https://github.com/nuxt/nuxt/pull/34125))
- **nitro:** Process isr/swr/cache keys ([d84278622](https://github.com/nuxt/nuxt/commit/d84278622))
- **nuxt:** Add `typeFrom` support for `imports.d.ts` template exports ([#​34135](https://github.com/nuxt/nuxt/pull/34135))
- **nuxt:** Ensure we inline styles for `hydrate-never` components ([#​34132](https://github.com/nuxt/nuxt/pull/34132))
##### 💅 Refactors
- **kit:** Add explicit return types for kit utilities ([6cd1289d1](https://github.com/nuxt/nuxt/commit/6cd1289d1))
- **nitro,nuxt,schema,vite:** Provide explicit return types ([1d2c0c25f](https://github.com/nuxt/nuxt/commit/1d2c0c25f))
- **kit,nuxt,schema:** Use named imports from `defu` + `consola` ([322dae3e0](https://github.com/nuxt/nuxt/commit/322dae3e0))
- Add explicit `.ts` file extensions to relative imports ([80778c0cd](https://github.com/nuxt/nuxt/commit/80778c0cd))
- **kit,nitro,nuxt,schema:** Reduce barrels + move `<>` to `as` ([f1713850c](https://github.com/nuxt/nuxt/commit/f1713850c))
- **nitro,nuxt:** Use `~` prefix for internal ssrContext properties ([#​33896](https://github.com/nuxt/nuxt/pull/33896))
- **nitro:** Add explicit return types for runtime utils ([a4fda917e](https://github.com/nuxt/nuxt/commit/a4fda917e))
- **nitro:** Move tree-shaken flags from replace plugin -> vfs ([#​33907](https://github.com/nuxt/nuxt/pull/33907))
- **nitro,nuxt,vite,webpack:** Use `status`/`statusText` + deprecate old props ([#​33912](https://github.com/nuxt/nuxt/pull/33912))
- **webpack:** Use RuntimeModule API for chunk preloads ([#​33930](https://github.com/nuxt/nuxt/pull/33930))
- **nuxt:** Use AST-aware function key injection ([#​33446](https://github.com/nuxt/nuxt/pull/33446))
- **nitro,nuxt,schema:** Use augments for nitro schema types ([#​34039](https://github.com/nuxt/nuxt/pull/34039))
- **nitro,rspack,vite,webpack:** Move cors handling -> nitro builder ([#​34048](https://github.com/nuxt/nuxt/pull/34048))
##### 📖 Documentation
- Split and improve `Module Author Guides` ([#​33803](https://github.com/nuxt/nuxt/pull/33803))
- Update links to module guide ([86d67b24f](https://github.com/nuxt/nuxt/commit/86d67b24f))
- Fix `useHead` return type ([#​33857](https://github.com/nuxt/nuxt/pull/33857))
- Add note that middleware doesn't run when rendering islands ([7df27c781](https://github.com/nuxt/nuxt/commit/7df27c781))
- Add note on default branch for layers ([#​33919](https://github.com/nuxt/nuxt/pull/33919))
- Add mcp setup instructions for claude desktop ([#​33914](https://github.com/nuxt/nuxt/pull/33914))
- Mention deno as package manager ([#​33875](https://github.com/nuxt/nuxt/pull/33875))
- Clarify purpose of `statusText` ([#​32834](https://github.com/nuxt/nuxt/pull/32834))
- Update lychee config and remove medium article link ([c0b4e0f28](https://github.com/nuxt/nuxt/commit/c0b4e0f28))
- Update module count and fix typo ([#​33950](https://github.com/nuxt/nuxt/pull/33950))
- Add DeepWiki badge ([#​33508](https://github.com/nuxt/nuxt/pull/33508))
- Give example of usage of `defineWrappedResponseHandler` ([#​33952](https://github.com/nuxt/nuxt/pull/33952))
- Provide cleaner example code for vitest projects ([#​33960](https://github.com/nuxt/nuxt/pull/33960))
- Improve `addImports` example ([#​34011](https://github.com/nuxt/nuxt/pull/34011))
- Update yarn create command ([4a3c08874](https://github.com/nuxt/nuxt/commit/4a3c08874))
- Update roadmap with a11y ([d3453d6a5](https://github.com/nuxt/nuxt/commit/d3453d6a5))
- Add a11y release ([#​34041](https://github.com/nuxt/nuxt/pull/34041))
- Remove Nuxtr from recommendations ([#​34045](https://github.com/nuxt/nuxt/pull/34045))
- Typo ([#​34050](https://github.com/nuxt/nuxt/pull/34050))
- Remove duplicate feature ([#​34058](https://github.com/nuxt/nuxt/pull/34058))
- Fix typo ([#​34057](https://github.com/nuxt/nuxt/pull/34057))
- Provide deno package manager examples ([#​34070](https://github.com/nuxt/nuxt/pull/34070))
- Update JSDoc for `config.experimental` properties ([#​34069](https://github.com/nuxt/nuxt/pull/34069))
- Fix transition types ([#​34082](https://github.com/nuxt/nuxt/pull/34082))
- Make custom wrapper recipe link more prominent ([#​34085](https://github.com/nuxt/nuxt/pull/34085))
- Remove `null` from `getCachedData` trigger ([f7cf3747e](https://github.com/nuxt/nuxt/commit/f7cf3747e))
- **nuxt:** Mention custom serializers in `useState` docs ([#​34105](https://github.com/nuxt/nuxt/pull/34105))
- Add info about runtime directories + type checking ([#​34097](https://github.com/nuxt/nuxt/pull/34097))
- Clarify module setups in `.nuxtrc` example ([#​34107](https://github.com/nuxt/nuxt/pull/34107))
- Remove duplicate entries in table ([#​34094](https://github.com/nuxt/nuxt/pull/34094))
- Clarify catch all notation for `addServerHandler` ([#​34060](https://github.com/nuxt/nuxt/pull/34060))
- Add layers directory documentation ([#​33967](https://github.com/nuxt/nuxt/pull/33967))
- Clarify type-checking context limitations for server routes ([#​33964](https://github.com/nuxt/nuxt/pull/33964))
- Add a tip for `appLayout` ([beda47955](https://github.com/nuxt/nuxt/commit/beda47955))
- Add docs for disabling modules by passing `false` to its options ([cdad9310c](https://github.com/nuxt/nuxt/commit/cdad9310c))
- Add info about caching payloads with isr/swr ([6e10ff04f](https://github.com/nuxt/nuxt/commit/6e10ff04f))
- Add example for async addVitePlugin ([1098254f7](https://github.com/nuxt/nuxt/commit/1098254f7))
- Add example of passing props to layouts ([1f9e6b82c](https://github.com/nuxt/nuxt/commit/1f9e6b82c))
- Mark vite plugin as not typed ([5e09fddfb](https://github.com/nuxt/nuxt/commit/5e09fddfb))
- Add warning about `source` from `<NuxtIsland>` ([1586bbb6e](https://github.com/nuxt/nuxt/commit/1586bbb6e))
##### 📦 Build
- Remove babel debugging plugin from jiti stub options ([bce8248b4](https://github.com/nuxt/nuxt/commit/bce8248b4))
- **vite:** Add build entries for `vite-node` entrypoints ([#​33893](https://github.com/nuxt/nuxt/pull/33893))
- **nuxt:** Tidy up subpath export types ([a63d4a014](https://github.com/nuxt/nuxt/commit/a63d4a014))
- Use `obuild` except for nuxt + nitro-server packages ([#​34049](https://github.com/nuxt/nuxt/pull/34049))
- **schema:** Fix `/builder-env` subpath types ([7f5034288](https://github.com/nuxt/nuxt/commit/7f5034288))
##### 🏡 Chore
- Add return types to debug plugins ([8f7554287](https://github.com/nuxt/nuxt/commit/8f7554287))
- Add `build:stub` command for those that need it ([3e3d3d37a](https://github.com/nuxt/nuxt/commit/3e3d3d37a))
- Revert change to how type augments are inserted ([c1b3590ff](https://github.com/nuxt/nuxt/commit/c1b3590ff))
- Update eslint config rule ([2717d8fd3](https://github.com/nuxt/nuxt/commit/2717d8fd3))
- Do not require aligned columns in tables ([8d3c5b371](https://github.com/nuxt/nuxt/commit/8d3c5b371))
- Lint ([f89d447a1](https://github.com/nuxt/nuxt/commit/f89d447a1))
- Explicitly import `node:process` ([#​33982](https://github.com/nuxt/nuxt/pull/33982))
- Add root scripts to lint context ([e22089f82](https://github.com/nuxt/nuxt/commit/e22089f82))
- Tidy up configs ([8b42d4c2b](https://github.com/nuxt/nuxt/commit/8b42d4c2b))
- Lint docs with eslint ([51da8e681](https://github.com/nuxt/nuxt/commit/51da8e681))
- Lint ([1cfd3c460](https://github.com/nuxt/nuxt/commit/1cfd3c460))
##### ✅ Tests
- Update tests for new version of nuxt/test-utils ([#​33842](https://github.com/nuxt/nuxt/pull/33842))
- Avoid unnecessary tick ([988f6657a](https://github.com/nuxt/nuxt/commit/988f6657a))
- Add regression test for asyncData HMR ([#​32182](https://github.com/nuxt/nuxt/pull/32182))
- Add test for page hmr resetting state ([#​32418](https://github.com/nuxt/nuxt/pull/32418))
- Add reproduction for vite pre-transform error ([#​31574](https://github.com/nuxt/nuxt/pull/31574))
- Add regression test for [#​32154](https://github.com/nuxt/nuxt/issues/32154) ([#​32154](https://github.com/nuxt/nuxt/issues/32154))
- Use `vi.hoisted` for klona mock ([#​34113](https://github.com/nuxt/nuxt/pull/34113))
##### 🤖 CI
- Directly call webhook url ([ce15997ce](https://github.com/nuxt/nuxt/commit/ce15997ce))
- Use new reusable triage workflows ([#​34072](https://github.com/nuxt/nuxt/pull/34072))
- Use new shared dependency review workflow ([8c01e1ce9](https://github.com/nuxt/nuxt/commit/8c01e1ce9))
##### ❤️ Contributors
- Florian Heuberger ([@​Flo0806](https://github.com/Flo0806))
- Octavio Araiza ([@​8ctavio](https://github.com/8ctavio))
- Daniel Roe ([@​danielroe](https://github.com/danielroe))
- Robin ([@​OrbisK](https://github.com/OrbisK))
- shaheer-arbisoft ([@​shaheer-arbisoft](https://github.com/shaheer-arbisoft))
- Matej Černý ([@​cernymatej](https://github.com/cernymatej))
- Francesco Mussoni ([@​solidusite](https://github.com/solidusite))
- Danila Poyarkov ([@​dannote](https://github.com/dannote))
- Victor Saa ([@​vis97c](https://github.com/vis97c))
- Teages ([@​Teages](https://github.com/Teages))
- Eli Sterken ([@​eli-sterk](https://github.com/eli-sterk))
- Ryota Watanabe ([@​wattanx](https://github.com/wattanx))
- Jakub Andrzejewski ([@​Baroshem](https://github.com/Baroshem))
- edison ([@​edison1105](https://github.com/edison1105))
- Max ([@​onmax](https://github.com/onmax))
- Aidan Hibbard ([@​aidanhibbard](https://github.com/aidanhibbard))
- Rahul Dogra ([@​rahuld109](https://github.com/rahuld109))
- Julien Huang ([@​huang-julien](https://github.com/huang-julien))
- abeer0 ([@​iiio2](https://github.com/iiio2))
- James Robert Lund III ([@​lundjrl](https://github.com/lundjrl))
- Philipp Wagner ([@​imphil](https://github.com/imphil))
- Maxime Pauvert ([@​maximepvrt](https://github.com/maximepvrt))
- Wind ([@​productdevbook](https://github.com/productdevbook))
- Agatem ([@​agatemosu](https://github.com/agatemosu))
- Pavel ([@​eL1fe](https://github.com/eL1fe))
- Alois Sečkár ([@​AloisSeckar](https://github.com/AloisSeckar))
- Lucie ([@​lihbr](https://github.com/lihbr))
- Sergiu Ravliuc ([@​YoSoySergio](https://github.com/YoSoySergio))
- Saeid Zareie ([@​Saeid-Za](https://github.com/Saeid-Za))
- Alireza Jahandideh ([@​Youhan](https://github.com/Youhan))
- kikuchan ([@​kikuchan](https://github.com/kikuchan))
- Ragura ([@​Ragura](https://github.com/Ragura))
- Josh Deltener ([@​hecktarzuli](https://github.com/hecktarzuli))
- Teena ([@​franklin-tina](https://github.com/franklin-tina))
- Frederik Bußmann ([@​freb97](https://github.com/freb97))
- Benjamin Oddou ([@​BenjaminOddou](https://github.com/BenjaminOddou))
- Mukund Shah ([@​mukundshah](https://github.com/mukundshah))
- Jessé Correia Lins ([@​linspw](https://github.com/linspw))
- Jannik Sohn ([@​janniksohn](https://github.com/janniksohn))
- Dawit ([@​oneminch](https://github.com/oneminch))
- Ali Sokkar ([@​NyllRE](https://github.com/NyllRE))
- Horu ([@​HigherOrderLogic](https://github.com/HigherOrderLogic))
- Anthony Fu ([@​antfu](https://github.com/antfu))
- Harlan Wilton ([@​harlan-zw](https://github.com/harlan-zw))
- Alexander Lichter ([@​TheAlexLichter](https://github.com/TheAlexLichter))
- Ryan Wilson ([@​rywils](https://github.com/rywils))
- Hugo ([@​HugoRCD](https://github.com/HugoRCD))
- yamachi4416 ([@​yamachi4416](https://github.com/yamachi4416))
</details>
---
### Configuration
📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 **Automerge**: Enabled.
♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 **Ignore**: Close this PR and you won't be reminded about this update again.
---
- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box
---
This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0Mi44NC4yIiwidXBkYXRlZEluVmVyIjoiNDIuODQuMiIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
This PR contains the following updates:
4.2.2→4.3.0Release Notes
nuxt/nuxt (nuxt)
v4.3.0Compare Source
Nuxt 4.3 brings powerful new features for layouts, caching, and developer experience – plus significant performance improvements under the hood.
📣 Some News
Extended v3 Support
Early this month, I opened a discussion to find out how the upgrade had gone from v3 to v4. I was really pleased to hear how well it had gone for most people.
Having said that, we're committed to making sure no one gets left behind. And so we will continue to provide security updates and critical bug fix releases beyond the previously announced end-of-life date of January 31, 2026, meaning Nuxt v3 will meet its end-of-life on July 31, 2026.
Preparing for Nuxt 5
We're closer than ever to the releases of Nuxt v5 and Nitro v3. In the coming weeks, the
mainbranch of the Nuxt repository will begin receiving initial commits for Nuxt 5. However, it's still business as usual.mainbranch4.xand3.xbranchesKeep an eye out on the Upgrade Guide – we'll be adding details about how you can already start migrating your projects to prepare for Nuxt v4 with
future.compatibilityVersion: 5.🗂️ Route Rule Layouts
But that's enough about the future. We have a lot of good things for you today!
First, you can now set layouts directly in route rules using the new
appLayoutproperty (#31092). This provides a centralized, declarative way to manage layouts across your application without scatteringdefinePageMetacalls throughout your pages.This might be useful for:
📦 ISR/SWR Payload Extraction
Payload extraction now works with ISR (incremental static regeneration), SWR (stale-while-revalidate) and cache
routeRules(#33467). Previously, only pre-rendered pages could generate_payload.jsonfiles.This means:
🧹 Dev Mode Payload Extraction
Related to the above, payload extraction now also works in development mode (#30784). This makes it easier to test and debug payload behavior without needing to run a production build.
🚫 Disable Modules from Layers
When extending Nuxt layers, you can now disable specific modules that you don't need (#33883). Just pass
falseto the module's options:🏷️ Route Groups in Page Meta
Route groups (folders wrapped in parentheses like
(protected)/) are now exposed in page meta (#33460). This makes it easy to check which groups a route belongs to in middleware or anywhere you have access to the route.This provides a clean, convention-based approach to route-level authorization without needing to add
definePageMetato every protected page.🎨 Layout Props with
setPageLayoutThe
setPageLayoutcomposable now accepts a second parameter to pass props to your layout (#33805):🔧
#serverAliasA new
#serveralias provides clean imports within your server directory (#33870), similar to how#sharedworks:The alias includes import protection – you can't accidentally import
#servercode from client or shared contexts.🪟 Draggable Error Overlay
The development error overlay introduced in Nuxt 4.2 is now draggable and can be minimized (#33695). You can:
This is a quality-of-life improvement when you're iterating on fixes and don't want the overlay blocking your view.
https://github.com/user-attachments/assets/nuxt_4-3_error_demo.mp4
⚙️ Async Plugin Constructors
Module authors can now use async functions when adding build plugins (#33619):
This enables true lazy loading of build plugins, avoiding unnecessary code loading when plugins aren't needed.
🚀 Performance Improvements
This release includes several performance optimizations for faster builds:
nuxt:ssr-stylesplugin is now significantly faster (#33862, #33865)rou3, removing the need forradix3in the client bundle and eliminating app manifest fetches (#33920)🎨 Inline Styles for Webpack/Rspack
The
inlineStylesfeature now works with webpack and rspack builders (#33966), not just Vite. This enables critical CSS inlining for better Core Web Vitals regardless of your bundler choice.⚠️ Deprecations
statusCode→status,statusMessage→statusTextIn preparation for Nitro v3 and H3 v2, we're moving to use Web API naming conventions (#33912). The old properties still work but are deprecated in advance of v5:
🐛 Bug Fixes
Notable fixes in this release:
keyattribute (#33958, #33963)useCookieunsafe number parsing during decode (#34007)NuxtPagenot re-rendering when nestedNuxtLayouthas layouts disabled (#34078)allowArbitraryExtensionsby default in TypeScript config (#34084)noUncheckedIndexedAccessto server tsconfig for safer typing (#33985)📚 Documentation
🎉 Nuxt 3.21.0
Alongside v4.3.0, we're releasing Nuxt v3.21.0 with many of the same improvements backported to the 3.x branch. This release includes:
setPageLayout,#serveralias, draggable error overlay, and morefalseuseCookienumber parsing, head component deduplication, and more✅ Upgrading
Our recommendation for upgrading is to run:
This will deduplicate your lockfile and help ensure you pull in updates from other dependencies that Nuxt relies on, particularly in the unjs ecosystem.
👉 Changelog
compare changes
🚀 Enhancements
#serveralias for server directory imports (#33870)crosswstypes (5b16a51f5)false(#33883)moduleDependenciesas an async function (#33504)appLayoutin route rules (#31092)setPageLayout(#33805)🔥 Performance
nuxt:ssr-stylesplugin (#33862)🩹 Fixes
router.replacein page hmr (#33897)page:loading:endin cache if already called (7789f73bd)NUXT_VITE_NODE_OPTIONS(41a564d23)appMiddlewarereferences invalid key (323f27bc8)nuxt/meta(01c2c9b13)keyfor tag deduplication in<Head>component (#33958)build.transpilewhen initialising vite (#33868)onUpgradearguments with types (#33988)rou3(2df4e1ae3)noUncheckedIndexedAccessto server tsconfig (#33985)shared/context (#33978)useRequestFetch(#33976)h3types to auto-imports (#34035)nuxt/schema(a6a044d81)NuxtPagewhen nestedNuxtLayouthas explicitly disabled layouts (#34078)allowArbitraryExtensionsby default (#34084)useAsyncDatadebounced execute post watcher flush (#34125)typeFromsupport forimports.d.tstemplate exports (#34135)hydrate-nevercomponents (#34132)💅 Refactors
defu+consola(322dae3e0).tsfile extensions to relative imports (80778c0cd)<>toas(f1713850c)~prefix for internal ssrContext properties (#33896)status/statusText+ deprecate old props (#33912)📖 Documentation
Module Author Guides(#33803)useHeadreturn type (#33857)statusText(#32834)defineWrappedResponseHandler(#33952)addImportsexample (#34011)config.experimentalproperties (#34069)nullfromgetCachedDatatrigger (f7cf3747e)useStatedocs (#34105).nuxtrcexample (#34107)addServerHandler(#34060)appLayout(beda47955)falseto its options (cdad9310c)sourcefrom<NuxtIsland>(1586bbb6e)📦 Build
vite-nodeentrypoints (#33893)obuildexcept for nuxt + nitro-server packages (#34049)/builder-envsubpath types (7f5034288)🏡 Chore
build:stubcommand for those that need it (3e3d3d37a)node:process(#33982)✅ Tests
vi.hoistedfor klona mock (#34113)🤖 CI
❤️ Contributors
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Enabled.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Renovate Bot.