nuxt
4.6.4 · 2 Nov 2026MIT3.6M / weekRepositoryHomepagenpmAtom feed
3.21.11 is the newest release of 3.x.
In short
38 new9 faster52 fixed72 internal
Security
Fixes 1 advisory that affected 3.15.4
- HighNuxt allows DOS via cache poisoning with payload rendering responseGHSA-jvhm-gjrh-3h93 · 19 Mar 2025Fixed in 3.16.0
18 advisories affect 3.16.0; 4.6.2 fixes the others
- ModerateNuxt exposes the message and data of unhandled errors thrown during server renderingGHSA-96x6-fvhx-49hg · 16 Nov 2026No fix yet
- ModerateNuxt: Incomplete fix for GHSA-6gq8-jgmh-3ffp: an encoded slash (`%2F`) in the request path bypasses route rules on catch-all page routesGHSA-f3x9-2chm-73c8 · 16 Nov 2026No fix yet
- ModerateNuxt: Server-side route rules (`redirect`, `headers`, `proxy`, `ssr`) are skipped for case-variant paths when routing is case-insensitiveGHSA-vjh5-4x84-xrqp · 22 Oct 2026No fix yet
- HighNuxt: Unauthenticated CPU exhaustion parsing and hashing the Nuxt island endpoint body before hash validationGHSA-9pgf-384g-p7mv · 5 Aug 2026Fixed in 3.21.10
- HighNuxt: Server-Side Remote Code Execution via Runtime Template Injection in Nuxt Server Island PropsGHSA-9473-5f9j-94wq · 5 Aug 2026Fixed in 3.21.10
13 more
- HighNuxt: Unauthenticated out-of-memory crash via unbounded v-for expansion in island renderingGHSA-hxcr-hm88-mpq6 · 5 Aug 2026Fixed in 3.21.10
- HighNuxt: Route-rule middleware bypass via case-sensitivity mismatch between vue-router and the routeRules matcherGHSA-mm7m-92g8-7m47 · 16 Jun 2026Fixed in 3.21.7
- ModerateNuxt server islands render `useHeadSafe` input without sanitisationGHSA-xfq5-w38q-pc2x · 22 Oct 2026Fixed in 4.6.2
- ModerateNuxt: Route rules are matched against the raw request path, so a percent-encoded segment can bypass `appMiddleware` on dynamic and catch-all routesGHSA-6gq8-jgmh-3ffp · 22 Oct 2026Fixed in 3.21.4
- ModerateNuxt: Unauthorized Component Instantiation via Server Island PropsGHSA-48hr-524c-v5w3 · 5 Aug 2026Fixed in 3.21.10
- ModerateNuxt: Reflected XSS in `<NuxtLink>` via unsanitised `javascript:` or `data:` URLGHSA-934w-87qh-qr26 · 16 Jun 2026Fixed in 3.21.7
- ModerateNuxt: URL-handling weaknesses in `navigateTo` and `reloadNuxtApp`: SSR open redirect, client-side script execution via the `open` option, and protocol-relative bypass in `reloadNuxtApp`GHSA-c9cv-mq2m-ppp3 · 16 Jun 2026Fixed in 3.21.7
- ModerateNuxt's route middleware is not enforced when rendering `.server.vue` pages via `/__nuxt_island/page_*`GHSA-hg3f-28rg-4jxj · 29 May 2026Fixed in 3.21.6
- ModerateNuxt: Reflected XSS in `navigateTo()` external redirectGHSA-fx6j-w5w5-h468 · 19 May 2026Fixed in 3.21.6
- LowNuxt: Incomplete fix for GHSA-934w-87qh-qr26: a `javascript:` URL prefixed with an ASCII control character executes from `<NuxtLink>` when `pages` is disabledGHSA-jjm6-p2m9-9w4x · 22 Oct 2026Fixed in 4.6.0
- LowCross-site scripting via <NoScript> slot content in Nuxt's head componentsGHSA-m3q2-p4fw-w38m · 16 Jun 2026Fixed in 3.21.7
- LowNuxt: `__nuxt_island` endpoint does not bind responses to request props, enabling shared-cache poisoningGHSA-g8wj-3cr3-6w7v · 19 May 2026Fixed in 3.21.6
- LowNuxt has Client-Side Path Traversal in Nuxt Island Payload RevivalGHSA-p6jq-8vc4-79f6 · 17 Sep 2025Fixed in 3.19.0
Release note
Highlights
There's a lot in this one!
A New New Nuxt
Say hello to create-nuxt, a new tool for starting Nuxt projects (big thanks to @devgar for donating the package name)!
It's a streamlined version of nuxi init - just a sixth of the size and bundled as a single file with all dependencies inlined, to get you going as fast as possible.
Starting a new project is as simple as:
npm create nuxt
screenshot of create nuxt app
Special thanks to @cmang for the beautiful ASCII-art. ❤️
Want to learn more about where we're headed with the Nuxt CLI? Check out our roadmap here, including our plans for an interactive modules selector.
Unhead v2
We've upgraded to unhead v2, the engine behind Nuxt's <head> management. This major version removes deprecations and improves how context works:
For Nuxt 3 users, we're shipping a legacy compatibility build so nothing breaks
The context implementation is now more direct via Nuxt itself
// Nuxt now re-exports composables while properly resolving the context
export function useHead(input, options = {}) {
const unhead = injectHead(options.nuxt)
return head(input, { head: unhead, ...options })
}If you're using Unhead directly in your app, keep in mind:
Import from Nuxt's auto-imports or
#app/composables/headinstead of@unhead/vueImporting directly from
@unhead/vuemight lose async context
Don't worry though - we've maintained backward compatibility in Nuxt 3, so most users won't need to change anything!
If you've opted into compatibilityVersion: 4, check out our upgrade guide for additional changes.
Devtools v2 Upgrade
Nuxt Devtools has leveled up to v2 (#30889)!
You'll love the new features like custom editor selection, Discovery.js for inspecting resolved configs (perfect for debugging), the return of the schema generator, and slimmer dependencies.
One of our favorite improvements is the ability to track how modules modify your Nuxt configuration - giving you X-ray vision into what's happening under the hood.
👉 Discover all the details in the Nuxt DevTools release notes.
Performance Improvements
We're continuing to make Nuxt faster, and there are a number of improvements in v3.16:
Using
exsolvefor module resolution (#31124) along with the rest of the unjs ecosystem (nitro, c12, pkg-types, and more) - which dramatically speeds up module resolutionSmarter module resolution paths (#31037) - prioritizes direct imports for better efficiency
Eliminated duplicated Nitro alias resolution (#31088) - leaner file handling
Streamlined
loadNuxtby skipping unnecessary resolution steps (#31176) - faster startupsAdopt
oxc-parserfor parsing in Nuxt plugins
All these speed boosts happen automatically - no configuration needed!
Shout out to CodSpeed with Vitest benchmarking to measure these improvements in CI - it has been really helpful.
To add some anecdotal evidence, my personal site at roe.dev loads 32% faster with v3.16, and nuxt.com is 28% faster. I hope you see similar results! ⚡️
Delayed Hydration Support
We're very pleased to bring you native delayed/lazy hydration support (#26468)! This lets you control exactly when components hydrate, which can improve initial load performance and time-to-interactive. We're leveraging Vue's built-in hydration strategies - check them out in the Vue docs.
<template> <!-- Hydrate when component becomes visible in viewport --> <LazyExpensiveComponent hydrate-on-visible /> <!-- Hydrate when browser is idle --> <LazyHeavyComponent hydrate-on-idle /> <!-- Hydrate on interaction (mouseover in this case) --> <LazyDropdown hydrate-on-interaction="mouseover" /> <!-- Hydrate when media query matches --> <LazyMobileMenu hydrate-on-media-query="(max-width: 768px)" /> <!-- Hydrate after a specific delay in milliseconds --> <LazyFooter :hydrate-after="2000" /> </template>
You can also listen for when hydration happens with the @hydrated event:
<LazyComponent hydrate-on-visible @hydrated="onComponentHydrated" />
Learn more about lazy hydration in our components documentation.
Advanced Pages Configuration
You can now fine-tune which files Nuxt scans for pages (#31090), giving you more control over your project structure:
export default defineNuxtConfig({
pages: {
// Filter specific files or directories
pattern: ['**/*.vue'],
}
})Enhanced Debugging
We've made debugging with the debug option more flexible! Now you can enable just the debug logs you need (#30578):
export default defineNuxtConfig({
debug: {
// Enable specific debugging features
templates: true,
modules: true,
watchers: true,
hooks: {
client: true,
server: true,
},
nitro: true,
router: true,
hydration: true,
}
})Or keep it simple with debug: true to enable all these debugging features.
Decorators Support
For the decorator fans out there (whoever you are!), we've added experimental support (#27672). As with all experimental features, feedback is much appreciated.
export default defineNuxtConfig({
experimental: {
decorators: true
}
})function something (_method: () => unknown) {
return () => 'decorated'
}
class SomeClass {
@something
public someMethod () {
return 'initial'
}
}
const value = new SomeClass().someMethod()
// returns 'decorated'Named Layer Aliases
It's been much requested, and it's here! Auto-scanned local layers (from your ~~/layers directory) now automatically create aliases. You can access your ~~/layers/test layer via #layers/test (#30948) - no configuration needed.
If you want named aliases for other layers, you can add a name to your layer configuration:
export default defineNuxtConfig({
$meta: {
name: 'example-layer',
},
})This creates the alias #layers/example-layer pointing to your layer - making imports cleaner and more intuitive.
Error Handling Improvements
We've greatly improved error messages and source tracking (#31144):
Better warnings for undefined
useAsyncDatacalls with precise file location informationError pages now appear correctly on island page errors
Plus, we're now using Nitro's beautiful error handling (powered by youch) to provide more helpful error messages in the terminal, complete with stacktrace support.
Nitro now also automatically applies source maps without requiring extra Node options, and we set appropriate security headers when rendering error pages.
Module Development Improvements
For module authors, we've added the ability to augment Nitro types with addTypeTemplate (#31079):
// Inside your Nuxt module
export default defineNuxtModule({
setup(options, nuxt) {
addTypeTemplate({
filename: 'types/my-module.d.ts',
getContents: () => `
declare module 'nitropack' {
interface NitroRouteConfig {
myCustomOption?: boolean
}
}
`
}, { nitro: true })
}
})Nitro v2.11 Upgrade
We've upgraded to Nitro v2.11. There are so many improvements - more than I can cover in these brief release notes.
👉 Check out all the details in the Nitro v2.11.0 release notes.
New unjs Major Versions
This release includes several major version upgrades from the unjs ecosystem, focused on performance and smaller bundle sizes through ESM-only distributions:
Unenv upgraded to v2 (full rewrite)
db0 upgraded to v0.3 (ESM-only, native node:sql, improvements)
Ohash upgraded to v2 (ESM-only, native node:crypto support, much faster)
Untyped upgraded to v2 (ESM-only, smaller install size)
Unimport upgraded to v4 (improvements)
c12 upgraded to v3 (ESM-only)
Pathe upgraded to v2 (ESM-only)
cookie-es upgraded to v2 (ESM-only)
Esbuild upgraded to v0.25
Chokidar upgraded to v4
Upgrading
As usual, our recommendation for upgrading is to run:
npx nuxi@latest upgrade --dedupe
This refreshes your lockfile and pulls in all the latest dependencies that Nuxt relies on, especially from the unjs ecosystem.
Changelog
Enhancements
nuxt: Granular debug options
nuxt: Add type hints for
NuxtPagenuxt: Support tracking changes to nuxt options by modules
nuxt: Allow disabling auto-imported polyfills
schema: Add runtime + internal type validation
kit,nuxt,schema: Support experimental decorators syntax
kit,nuxt: Allow multiple nuxts to run in one process
kit: Add named layer aliases
kit,nuxt,vite:
directoryToURLto normalise pathsnuxt: Allow forcing
start/setin loading indicatornuxt: Allow specifying glob patterns for scanning
pages/nuxt: Add types for default
NuxtLinkslotnuxt: Delayed/lazy hydration support
vite: Add vite's modulepreload polyfill
nuxt: Show source file when warning about undefined useAsyncData
kit,nuxt: Augment nitro types with
addTypeTemplatekit,nuxt: Resolve template imports from originating module
nuxt: Use
oxc-parserinstead of esbuild + acornnuxt: Upgrade to unhead v2
nuxt: Align nuxt error handling with nitro
Performance
nuxt: Remove duplicated nitro alias resolution
kit: Try non-subpath routes first to resolve nuxt modules
nuxt: Migrate to use
exsolvefor module resolutionkit: Skip extra module resolution step in
loadNuxt
Fixes
nuxt: Ensure
<NuxtLayout>fallbackprop is typednuxt: Assign slot to be rendered for client components
nuxt,vite: Do not override vite import conditions
nuxt: Prevent
keepalivecache resetnuxt: Remove
divwrapper in client-only pagesschema: Update type import to
nitropackvite: Use resolveId from vite-node to resolve deps
schema: Normalise additional experimental options
nuxt: Delete existing properties in app config HMR
schema: Return
nullfrom resolve functionsschema: Check if
app.head.metavalues are undefinednuxt: Make
shared/directories available within layerskit: Ensure nuxt is loaded from cwd rather than parent dir
ui-templates: Remove extra
<pre>when rendering dev errorsnuxt: Use tsx loader for jsx blocks as well
Remove unimplemented
page:transition:starttypekit: Expose module dependency errors
nuxt: Deprioritise layer css imports
nuxt: Ensure
provide/injectwork insetupofdefineNuxtComponentnuxt: Decode URI components in cache driver methods
nuxt: Use
_for NuxtIsland name on server pagesnuxt: Use
ohashto calculate legacy async data key without hashnuxt,schema: Resolve
shareddir from configkit,schema: Set esbuild target for experimental decorators
nuxt: Set
nuxt.options.pagesto detected configurationnuxt: Warn when
definePageMetadoes not receive an objectnuxt: Fix nitro import statements for v2
nuxt: Update path to
no-ssrmiddleware handlernuxt: Align type of custom
navigatewithvue-routernuxt: Show error page on island page error
nuxt: Do not render payloads if disabled, and correct regexp
nuxt: Add backwards-compatible serialisation for
nuxt.options.pagesui-templates: Escape inline scripts correctly in ui templates
nuxt: Add back fallback nuxtlink type signature
kit: Provide default extensions in
resolveModulenuxt: Provide default extensions in
resolveTypePathnuxt: Strip query before generating payload url
schema: Resolve workspaceDir to closest git config
kit: Include declaration files when resolving
compilerOptions.pathsnuxt: Consolidate head component context
nuxt: Resolve shared externals to absolute paths
nuxt: Skip deep merge in dev mode for prototype keys
schema: Use
RawVueCompilerOptionsfor unresolvedtsconfignuxt: Ensure externals are resolved first
nuxt: Ensure we strip all chars in payload url
nuxt: Exempt nitro from import protections
nuxt: Normalise error url to pathname
nuxt: Ensure head components are reactive
nuxt: Preserve query/hash when calling
navigateTowith replacenuxt: Apply ignore rules to nitro
devStoragenuxt: Fall back to wasm if oxc native bindings are missing
nuxt: Pass
useFetchfunction name on server for warningvite: Prevent overriding server build chunks
nuxt: Strip query in
x-nitro-prerenderheader
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.