Table of Content

Next.js Documentation



Next.js is a React framework for building full-stack web applications. You use React Components to build user interfaces, and Next.js for additional features and optimizations.

Under the hood, Next.js also abstracts and automatically configures tooling needed for React, like bundling, compiling, and more. This allows you to focus on building your application instead of spending time with configuration.

Whether you're an individual developer or part of a larger team, Next.js can help you build interactive, dynamic, and fast React applications.


Main Features


FeatureDescription
RoutingA file-system based router built on top of Server Components that supports layouts, nested routing, loading states, error handling, and more.
RenderingClient-side and Server-side Rendering with Client and Server Components. Further optimized with Static and Dynamic Rendering on the server with Next.js. Streaming on Edge and Node.js runtimes.
Data FetchingSimplified data fetching with async/await in Server Components, and an extended fetch API for request memoization, data caching and revalidation.
StylingSupport for your preferred styling methods, including CSS Modules, Tailwind CSS, and CSS-in-JS
OptimizationImage, Fonts, and Script Optimizations to improve your application's Core Web Vitals and User Experience.

App Router vs Pages Router


Next.js has two different routers: the App Router and the Pages Router. The App Router is a newer router that allows you to use React's latest features, such as Server Components and Streaming. The Pages Router is the original Next.js router, which allowed you to build server-rendered React applications and continues to be supported for older Next.js applications.

In this docs, we'll learn Page router first and then the App router.

To get the most out of our docs, it's recommended that you have a basic understanding of HTML, CSS, and React.