nuxt
4.6.4 · 2 Nov 2026MIT3.5M / weekRepositoryHomepagenpmAtom feed
2.18.1 is the newest release of 2.x.
In short
7 breaking4 deprecated30 new4 fixed14 changed
- Breaking
We now use Webpack 4. We announced 2.x and started publishing latest changes as
nuxt-edgepackage at March. But we wanted to make sure that most of the plugins were updated and stable before releasing a stable version of Nuxt.js - Breaking
Due to server/client artifact isolation (PR #3758), external
build.publicPathneed to upload built content to.nuxt/dist/clientdirectory instead.nuxt/dist. - Breaking
ESM is supported everywhere you can now use
export/importsyntax innuxt.config.js,serverMiddlewareandmodules. - Breaking
Upgraded to use Babel 7 (PR #3667)
- Breaking
Use
postcss-preset-envinstead ofpostcss-cssnext(notes)) (PR #3291), configbuild.postcss.presetis forpostcss-preset-env options - Breaking
Introducing nuxt-start for runtime only and nuxt-legacy to support Node < 8
- Breaking
Due to
css-loaderupgrade, use~assetsinstead of~/assetsfor alias in<url> CSS data type, e.g.,background: url("~assets/banner.svg")(PR #3741) - Deprecated
The
vendorarray isn't used anymore because of Webpack 4
Security
3 advisories affect 2.0.0; 4.6.0 fixes them
- Moderatenuxt vulnerable to Cross-site Scripting in navigateTo if used after SSRGHSA-vf6r-87q4-2vjf · 5 Aug 2024Fixed in 3.12.4
- 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
Release note
Migration guide for 2.0.0
Your migration is mostly straightforward as Nuxt 2 does not makes breaking changes. So you can try your chance and simply upgrade to Nuxt 2 using yarn add nuxt@^2.0.0 or npm install nuxt@^2.0.0 😉
The long but peaceful approach
Carefully read release notes
If you are using a VCS for your project commit and push latest changes and then checkout into a new branch
Stop any Nuxt process
Delete all directories
.nuxt,node_modules,yarn.lockandpackage.lock.jsonEnsure you are using the latest node version (Node 10.x and NPM >= 5 are recommended)
Upgrade
nuxt.config.js,modulesandserverMiddlewareto useimport/exportinstead ofrequireEnsure webpack and vue dependencies are not explicitly set inside your
package.json, if so please upgrade them to match Nuxt used versionsDo
npm installoryarn installUse
npm outdatedoryarn outdatedand manually update any other dependency with careIf you have a CDN deployment system, please make sure you have updated CI/CD configurations to publish
.nuxt/dist/clientinstead of.nuxt/distIf you are using
build.extend, make sure your changes are compatible with Webpack 4.
Still Having problems? Make a bug report at CMTY or reach us using Discord
Major changes
- Breaking
We now use Webpack 4. We announced 2.x and started publishing latest changes as
nuxt-edgepackage at March. But we wanted to make sure that most of the plugins were updated and stable before releasing a stable version of Nuxt.js - Breaking
Due to server/client artifact isolation (PR #3758), external
build.publicPathneed to upload built content to.nuxt/dist/clientdirectory instead.nuxt/dist. - Breaking
ESM is supported everywhere you can now use
export/importsyntax innuxt.config.js,serverMiddlewareandmodules. - Breaking
Upgraded to use Babel 7 (PR #3667)
- Breaking
Use
postcss-preset-envinstead ofpostcss-cssnext(notesxt)) (PR #3291), configbuild.postcss.presetis forpostcss-preset-env options - Breaking
Introducing nuxt-start for runtime only and nuxt-legacy to support Node < 8
- Breaking
Due to
css-loaderupgrade, use~assetsinstead of~/assetsfor alias in<url> CSS data type, e.g.,background: url("~assets/banner.svg")(PR #3741)
Features
watchQuerylets you observe query strings and execute component methods (asyncData, fetch, validate, layout etc) on changeYou can now Ignore pages with a prefix (PR #2594)
Internal hooks can be set hierarchically in
nuxt.config.js(PR #3766)Added
loading: falseoption to pages, see example, (PR #3629)New stores modules can now be built by a combination of files (
actions.js,mutations.js,getters.jsandstate.js) along withindex.js(PR #3636)Support functional filenames for webpack assets (PR #3787)
Server middleware watchers support (PR #3718)
HTTPS and Unix sockets support out of the box (PR #3831)
Support
serveroption innuxt.config.jsto setHOSTandPORT(PRs #3701)Support using
NUXT_HOST,NUXT_PORTenvironment variables (PR #3651)Configure Vue directly in
nuxt.config.js(PR #3655)Add preset option for postcss in
nuxt.config.js(PR #3734)Make compression middleware customizable
Environment variables starting with
NUXT_ENV_will be automatically included inprocess.envno-ssrhas been upgraded tovue-no-ssr 1.0.0, it supportsplaceholderTag
Enhancements
Fix HTML script tag in core/renderer to remove W3C warning (PR #2971)
Add
render:contexthook (PR #3294)Replace
background-colortobackgroundinloadingIndicator(PR #3656), so you can use an image or some gradient for your background in SPA mode!Correctly center
loadingIndicatorwhen using IE (PR #3779)Add
watchoption to watch custom files to restart the Nuxt.js server (default:nuxt.config.jsandserverMiddlewarefiles) (PRs #3633 and #3718)Isolate client and server artifacts (PR #3758) for better security of SSR bundles.
Using webpackbar and consola for a sexier CLI experience and better CI compatibility.
Change webpack asset names to names for development and to filehashes for production. (PR #3789). Also, prevent assets name collision in dev mode (Issue #3786)
Call global Vue errorHandler in fetch and asyncData (PR #3652, #3781)
Error page rendering before redirect (PR #3782)
Disable template literals in lodash templates (PR #3753)
Display proper error when the specified plugin isn't found (PR #3672)
Customize the path to your
app.htmltemplate innuxt.config.js(PR #3678)Quiet option when building your Nuxt app (PR #3705)
Minify extracted CSS assets
Add tests to check for changed files
Overwrite
store.registerModuleto work seamlessly with SSRAdd throttle option to skip progress for fast loads
Deprecated
- Deprecated
The
vendorarray isn't used anymore because of Webpack 4 - Deprecated
We removed DLL support as it was not stable enough and Webpack 4 is much faster now.
- Deprecated
Obsolete AggressiveSplittingPlugin (PR #3545)
- Deprecated
The
render.gzipoption. Userender.compressorinstead.
Internals
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.