Skip to the page

Build, deploy and upgrade · senior

Upgrading to Next.js 16: what breaks

Next.js 16 removed sync access to request APIs, renamed middleware to proxy, made Turbopack the default, changed revalidateTag, image defaults and parallel-route rules, and dropped AMP, next lint and runtime config; plan the upgrade on a branch with codemods and tests.

The notes

What you must know

  • Requirements: Node.js 20.9+, TypeScript 5.1+, modern browsers (Chrome/Edge/Firefox 111+, Safari 16.4+).
  • Async only: await params, await searchParams, await cookies(), await headers(), await draftMode() (sync access removed). Metadata image routes get async params.
  • middleware.ts -> proxy.ts (Node runtime). revalidateTag(tag) single argument deprecated: use revalidateTag(tag, "max") or updateTag(tag).
  • Turbopack default: custom webpack() ignored (use --webpack or migrate); experimental.turbopack moved to top-level turbopack.
  • Removed: AMP, next lint (use ESLint/Biome; codemod next-lint-to-eslint-cli), serverRuntimeConfig/publicRuntimeConfig (use env vars), experimental.ppr and experimental_ppr (use Cache Components), experimental.dynamicIO (renamed cacheComponents), automatic scroll-behavior: smooth.
  • Behaviour changes: every parallel slot needs default.js; image defaults (qualities [75], 4 h TTL, etc.); images.domains and next/legacy/image deprecated; ESLint flat config default.
  • Tools: npx @next/codemod@canary upgrade latest; in 16.4 npx next@canary upgrade --agent=latest prepares migration guides, codemods and checks for a coding agent.
  • Process: upgrade one minor at a time on a branch, read the upgrade guide, run codemods, then type check, E2E and visual tests, compare performance, canary deploy. Keep up with monthly security patches (15.5.x is maintenance LTS, 16.4.x active LTS as of Nov 2026).

The red pen

Common traps: mistake → fix

  • Mistake: "Upgrade React, Next and every dependency in one PR"

    Fix: hard to find what broke.

  • Mistake: "Disable type errors to ship"

    Fix: the async params changes are exactly what types catch.

  • Mistake: "Pin back to 15 forever"

    Fix: you lose security fixes once it leaves maintenance.

Easy to hard

Questions interviewers ask, easy to hard

  1. We upgraded to Next 16: the build ignores our webpack() function, params access errors, and revalidateTag warns. It is Friday. What is going on?
  2. What does the async request API codemod do?
  3. What else was removed in 16?
  4. How do you de-risk a framework upgrade in a large app?

Your first interview is free

Sign up and start with a 15-minute interview with the full report, and an English conversation. No card needed.

Start your free interview