Next.js

Next.js is the most widely used React framework, maintained by Vercel. It adds file-based routing, server rendering, static generation, incremental static regeneration, image and font optimisation, edge runtime support, and a fully integrated build pipeline on top of React. Next.js is the default starting point for new React applications at most companies.

Routing modes

  • App Router (current). File-based routing with React Server Components, layouts, parallel routes, intercepting routes, server actions. The recommended approach for new projects.
  • Pages Router (legacy). The older file-based router still supported alongside App Router.

Rendering modes

  • Static (SSG). Pre-rendered at build time; served from CDN.
  • Server-rendered (SSR). Rendered per-request on the server.
  • Incremental Static Regeneration (ISR). Static pages refreshed in the background after a configurable interval.
  • Streaming. Server flushes HTML in chunks as components resolve; Suspense for loading states.
  • Edge runtime. Run handlers and components close to users on Vercel Edge, Cloudflare Workers (with adapter).

Hosting

First-class on Vercel; also runs on Netlify, AWS Amplify, Cloudflare Pages, self-hosted Node servers, and standalone Docker images.

🔗
Related Terms
React, SSR, CSR, TypeScript, Vite.

Subscribe to Sahil's Playbook

Clear thinking on product, engineering, and building at scale. No noise. One email when there's something worth sharing.
[email protected]
Subscribe
Mastodon