.vue files from the beginning while enjoying hot module replacement in development and a performant application in production with server-side rendering by default.
Nuxt has no vendor lock-in, allowing you to deploy your application everywhere, even on the edge.
If you want to play around with Nuxt in your browser, you can try it out in one of the online sandboxes available in the installation guide.
Automation and Conventions
Nuxt uses conventions and an opinionated directory structure to automate repetitive tasks and allow you to focus on pushing features. The configuration file can still customize and override its default behaviors.File-based routing
Define routes based on the structure of your
app/pages/ directory. This makes it easier to organize your application and avoid manual route configuration.Code splitting
Nuxt automatically splits your code into smaller chunks, which helps reduce the initial load time of your application.
Server-side rendering
Built-in SSR capabilities out of the box - you don’t have to set up a separate server yourself.
Auto-imports
Write Vue composables and components in their respective directories and use them without importing, with benefits of tree-shaking and optimized JS bundles.
Data-fetching utilities
Composables to handle SSR-compatible data fetching with different strategies.
Zero-config TypeScript
Write type-safe code without having to learn TypeScript with auto-generated types and
tsconfig.json.Configured build tools
Uses Vite by default to support hot module replacement (HMR) in development and bundling your code for production with best-practices baked-in.
Server-Side Rendering
Nuxt comes with built-in server-side rendering (SSR) capabilities by default, without having to configure a server yourself, which has many benefits for web applications:- Faster initial page load time - Nuxt sends a fully rendered HTML page to the browser, which can be displayed immediately. This provides a faster perceived page load time and better user experience (UX), especially on slower networks or devices.
- Improved SEO - Search engines can better index SSR pages because the HTML content is available immediately, rather than requiring JavaScript to render the content on the client-side.
- Better performance on low-powered devices - It reduces the amount of JavaScript that needs to be downloaded and executed on the client-side, which can be beneficial for low-powered devices that may struggle with processing heavy JavaScript applications.
- Better accessibility - The content is immediately available on the initial page load, improving accessibility for users who rely on screen readers or other assistive technologies.
- Easier caching - Pages can be cached on the server-side, which can further improve performance by reducing the amount of time it takes to generate and send the content to the client.
nuxt generate, disable SSR globally with the ssr: false option or leverage hybrid rendering by setting up the routeRules option.
Server Engine
The Nuxt server engine Nitro unlocks new full-stack capabilities. In development, it uses Rollup and Node.js workers for your server code and context isolation. It also generates your server API by reading files inserver/api/ and server middleware from server/middleware/.
In production, Nitro builds your app and server into one universal .output directory. This output is light: minified and removed from any Node.js modules (except polyfills). You can deploy this output on any system supporting JavaScript, from Node.js, Serverless, Workers, Edge-side rendering or purely static.
Production-ready
A Nuxt application can be deployed on a Node or Deno server, pre-rendered to be hosted in static environments, or deployed to serverless and edge providers.Modular
A module system allows you to extend Nuxt with custom features and integrations with third-party services.Architecture
Nuxt is composed of different core packages:- Core engine: nuxt
- Bundlers: @nuxt/vite-builder, @nuxt/rspack-builder and @nuxt/webpack-builder
- Command line interface: @nuxt/cli
- Server engine: nitro
- Development kit: @nuxt/kit