Skip to content
Sandeep Kumar
Security

Next.js security release: patch to 16.4.5 or 15.5.29

Next.js fixed seven vulnerabilities on 3 November 2026, led by a high-severity cross-tenant cache leak with Cache Components. Who is exposed and what to do.

Act now

Act now: Upgrade if you run Next.js 16.x below 16.4.5 or 15.x below 15.5.29. Urgent if you use Cache Components with tenant or user data.

Sandeep Kumar, Full-stack EngineerSandeep KumarFull-stack Engineer

Next.js shipped a security release on 3 November 2026: 16.4.5 for the 16.4 line (Active LTS) and 15.5.29 for 15.5 (Maintenance LTS). If you're on anything older in either line, upgrade.

bash
npm install next@16.4.5    # 16.x apps
npm install next@15.5.29   # 15.x apps

The advance notice on 27 October promised "seven medium vulnerabilities". The release itself rates the first one high. Read the advisories, not the preview.

Who is exposed

Four of the seven fixes are about caching, and they only matter if you've turned on Cache Components (use cache).

The worst one leaks one tenant's cached data to another. It needs a public use cache function that reads a root parameter, such as a tenant ID, and is called both directly and through unstable_cache.

On a cold cache, a concurrent request could get someone else's result, and that result could then be stored and served to later callers until it was revalidated or evicted.

The other three cache bugs follow the same pattern:

  • nested use cache functions that store an entry before its root-parameter dependencies are recorded
  • binary arguments that collapse to the same cache key
  • a shared page shell that a crafted URL could poison on self-hosted next start with Partial Prefetching off

The remaining three are narrower:

  • Self-hosted apps that return an attacker-controlled fetched Response unchanged, behind an HTTP/1.1 proxy that pipelines requests on a shared connection, could send responses to the wrong client.
  • Edge route handlers that set cookies with NextResponse.cookies.set() copied them into an internal x-middleware-set-cookie header, which same-origin JavaScript can read even for HttpOnly cookies.
  • An image from an allowed source could pass as AVIF and slip past images.dangerouslyAllowSVG: false.

My read

If you run a multi-tenant app on Cache Components, treat this as urgent and check whether anything was served across tenants since you enabled it. I wrote about why this class of bug is so easy to ship in multi-tenant data isolation: the cache key is part of your access control, whether you meant it to be or not.

For everyone else it's a routine upgrade. This blog runs Next.js 16.4.6 without Cache Components, so none of the cache issues applied here, but I'd still upgrade rather than reason my way out of each advisory. The App Router caching guide covers what Cache Components changes about where your data is stored.

More news