Next.js 16 Release
Next.js 16 marks a significant milestone with the stable release of Turbopack, the introduction of the Build Adapters API (alpha), and major improvements to caching, routing, and developer experience.
Build Adapters API (Alpha)
The Build Adapters API is a groundbreaking new feature that enables deployment platforms and custom build integrations to hook directly into the Next.js build process. This addresses long-standing pain points for hosting providers like Netlify, Cloudflare, and AWS Lambda, who previously had to reverse-engineer undocumented manifests and patch Next.js internals.
Key Benefits
- Official Integration Points: Platforms can now modify Next.js configuration and process build output through documented APIs instead of custom hacks.
- Uniform Deployment: Vercel and all other hosting providers use the same adapter hooks, ensuring identical behavior across environments.
- Better Control: Adapters receive structured manifests of routes, functions, and assets, eliminating the need to rely on undocumented JSON files.
Implementation
To use an adapter, configure it in your Next.js configuration:
// next.config.js
const nextConfig = {
experimental: {
adapterPath: require.resolve('./my-adapter.js'),
},
};
module.exports = nextConfig;The adapter API provides hooks like modifyConfig (pre-build) and onBuildComplete (post-build) to customize the build process. Learn more in the RFC announcement.
Major Features
Turbopack (Stable)
Turbopack is now the default bundler, delivering:
- 2–5× faster production builds
- Up to 10× faster Fast Refresh during development
- Filesystem caching support (beta) for even better performance
Developers can opt out with --webpack if needed.
Cache Components
New opt-in caching using the "use cache" directive with automatic cache key generation. This completes the Partial Pre-Rendering (PPR) story and provides unified caching behavior.
proxy.ts (Replaces middleware.ts)
The new proxy.ts file clarifies the network boundary and runs exclusively in the Node.js runtime. The previous middleware.ts is now deprecated.
Enhanced Routing & Navigation
- Layout deduplication: Shared layouts are downloaded once instead of per-URL
- Incremental prefetching: Only prefetch uncached content
- Smart cancellation: Cancels requests when links leave the viewport
Improved Caching APIs
revalidateTag()- Now requirescacheLifeprofile for stale-while-revalidate (SWR)updateTag()- New Server Actions API with read-your-writes semanticsrefresh()- Refreshes uncached data only
React 19.2 & React Compiler
Full support for React 19.2 features including:
- View Transitions
useEffectEvent()- Activity component
The React Compiler is now stable, providing built-in automatic memoization via Babel plugin integration.
Next.js DevTools MCP
Model Context Protocol integration enables AI-assisted debugging with unified logs, automatic error access, and contextual page awareness.
Developer Experience
- Improved Logging: Development and build logs now show time spent in each stage (Compile, Render)
- Simplified create-next-app: Redesigned with App Router by default, TypeScript-first, Tailwind CSS, and ESLint
- Better Terminal Output: Clearer formatting with improved error messages and performance metrics
Breaking Changes
Version Requirements
- Node.js: 20.9+ (LTS; Node.js 18 no longer supported)
- TypeScript: 5.1.0+
- Browsers: Chrome 111+, Edge 111+, Firefox 111+, Safari 16.4+
Removed Features
- AMP support
next lintcommandserverRuntimeConfigandpublicRuntimeConfigexperimental.pprandexperimental.dynamicIOflags- Synchronous access to
params,searchParams,cookies(),headers()(now async)
Notable Changes
- Image defaults:
minimumCacheTTLchanged from 60s to 4 hours,qualitiesdefaults to [75] - Parallel Routes: All slots now require explicit
default.js - Separate Output Directories:
next devandnext builduse separate directories
Upgrade Instructions
Use the automated codemod for the smoothest upgrade experience:
npx @next/codemod@canary upgrade latestOr upgrade manually:
npm install next@latest react@latest react-dom@latestFor new projects:
npx create-next-app@latestSource: Next.js Blog