Next.js 16.4: Cache Components Recommended for Every App, Agent Upgrades and React 19.3
Next.js 16.4 (6 October 2026) recommends Cache Components for all apps and enables them by default in create-next-app, adds ensureStatic and prefetch controls, a next upgrade --agent command for coding agents, smaller Turbopack caches and bundles, React 19.3, and experimental lazy dynamic imports and a Rust React Compiler.
Next.js 16.4 shipped on 6 October 2026. The headline: the Next.js team now recommends Cache Components — the explicit 'use cache' caching model — for every app, and it's slated to become the default in Next.js 17.
Cache Components, recommended
- New apps from
create-next-apphave Cache Components enabled by default. - Enable it in existing apps with
cacheComponents: trueandpartialPrefetching: trueinnext.config.ts. ensureStatic('navigation','prefetch'or'shell') fails the build if dynamic content sneaks into a route you want static — useful for marketing pages, blogs and shops.navigation()andprefetch()fromnext/cachelet you exclude parts of a page from prefetches, deferring expensive data until the user actually navigates.
(Next.js Cache Components Explained)
Built for coding agents
npx next@canary upgrade --agent=latestprepares version-specific migration guides, codemods and verification steps for an AI agent to carry out the upgrade.experimental.agentUpgradenudges you (or your agent) duringnext dev/next buildwhen an upgrade is available — by default only for security fixes.- Agent feedback (experimental) lets agents draft reports of framework problems that you review before sending.
- Skills for adopting Cache Components and a
next-bundle-optimizerskill for shrinking bundles.
Improvements for every app
- Turbopack's disk cache uses 20–25% less space.
- Lazy server HMR: only routes you're viewing recompile on server changes.
- Smaller production bundles: shorter CSS Module class names and export mangling, plus a shared Turbopack runtime chunk.
- React 19.3: stable View Transitions, Fragment Refs and the
browser()API. - A much richer Turbopack Bundle Analyzer.
Experimental
- Rust React Compiler (
turbopackRustReactCompiler) with faster checks and lower memory. - Lazy dynamic imports, disk cache garbage collection, and worker threads for loaders (falls back to child processes on Node 24.13.1+ due to a Node bug).
- Additional roots for symlinked packages and pnpm's global virtual store. (pnpm Workspaces)
Upgrade
npm install next@latest
Then run your build and tests. If you're on 16.3 or 15.5, make sure you've at least applied the 30 September security release.
Source: Next.js 16.4 release post
EasySpawn self-hosts Next.js apps on a persistent server with HTTPS and Postgres, and Claude Code can run the agent-guided upgrade on a branch for you to review. See how it works or join the waitlist.
Related: Self-Hosting Next.js Without Vercel
Keep reading
What Is v0? Vercel's AI App Builder Explained
v0 is Vercel's AI app builder: describe a UI or an app and it generates a real Next.js project with React, Tailwind and shadcn/ui, with a live preview and one-click publishing to Vercel. What it's good at, how it differs from Lovable and Bolt, and what to know before shipping.
Unexpected End of JSON Input: Causes and Fixes
"Unexpected end of JSON input" means you parsed an empty or cut-off string, usually response.json() on a 204 or an error. How to find the real response and fix it.