Nuxt is the full-stack framework for Vue, much as Next.js is for React. It gives you file-based routing from the pages folder, layouts, automatic imports of components and composables, server-side rendering, static generation and API routes powered by its Nitro server engine. You still write ordinary Vue single-file components, but Nuxt decides how and where they render. Learning it well means understanding the line between server and client and how data fetching fits across it. Learnr teaches Nuxt through short lessons and small build tasks matched to your Vue experience.
How to learn Nuxt, step by step
- Learn Vue 3 and the Composition API first. Nuxt is Vue plus conventions, so be comfortable with ref, computed, props, emits and script setup. Trying to learn both at once makes it hard to tell which layer an error comes from.
- Map files to routes. Create pages like index.vue, about.vue and users/[id].vue, then add a default layout and a route middleware that redirects guests. Seeing the folder become the router is the first Nuxt habit to build.
- Fetch data the Nuxt way. Use useFetch or useAsyncData in pages instead of calling fetch inside onMounted. Check the network tab to confirm data is fetched once on the server and passed to the client during hydration.
- Write a small API in the server folder. Add a route under server/api that reads from a database or a JSON file and call it from a page. Keep secrets in runtimeConfig so they stay on the server and never reach the browser bundle.
- Experiment with rendering modes. Use routeRules to prerender a marketing page, server-render a dashboard and keep an admin area client-only. Fix any hydration mismatch warnings, usually caused by dates, random values or browser-only APIs.
- Deploy and keep practicing. Deploy to a Node host or an edge platform using a Nitro preset. Learnr lessons in short daily sessions help keep composables, rendering modes and data-fetching rules distinct while you build more pages.
What you'll learn
- Build pages, nested routes and dynamic routes from the file system
- Fetch data with useFetch and useAsyncData without double requests
- Write server API routes in the server folder
- Choose rendering per route with SSR, prerendering or client-only modes
- Manage shared state with useState or Pinia and configure SEO metadata
How long does it take to learn Nuxt?
Vue developers can build and deploy a small Nuxt site in 1 to 3 weeks and become comfortable with rendering modes and server routes within 6 to 8 weeks at 5 hours a week. If you are new to Vue, add 4 to 6 weeks first.
What you need before you start
HTML, CSS and JavaScript, plus working knowledge of Vue 3 components. Basic Node.js and npm usage helps, and familiarity with TypeScript is useful because Nuxt projects use it by default.
Common mistakes to avoid
- Accessing window or localStorage during server rendering, which crashes or causes hydration mismatches. Guard browser code or move it into onMounted or a client-only component.
- Fetching data in onMounted, so pages render empty for search engines and users wait longer. Use useFetch or useAsyncData instead.
- Putting API keys in public runtime config, which ships them to every visitor. Keep private values in the server-only part of runtimeConfig.
How Learnr builds your course
Type your topic
Tell Learnr you want to learn Nuxt, or get as specific as you like.
Get a personalized course
Learnr instantly builds a full Nuxt course tailored to your goal and skill level.
Learn and level up
Move through bite-sized lessons and interactive practice, earning XP and keeping your streak.
Nuxt questions, answered
Nuxt or Next.js, which should I learn?
Choose by the component library you prefer. Nuxt is for Vue and Next.js is for React, and they solve the same problems of routing, rendering and server code. If you already know Vue, Nuxt is the natural next step.
Do I need Nuxt for every Vue project?
No. A plain Vue app built with Vite is fine for dashboards behind a login. Nuxt pays off when you need SEO, server rendering, static pages or API routes in the same project.
Explore more courses
More programming and tech courses
- Learn jQuery
- Learn Sass
- Learn Electron.js
- Learn Firebase
- Learn Operating Systems
- Learn Compiler Design
- Learn Distributed Systems
- Learn Reverse Engineering
See all programming and tech courses
Ready to learn Nuxt?
Start your free, personalized Nuxt course in seconds. It will be typed in and ready when you get there.
Start learning NuxtFree to start. No credit card.