
Next.js Storefront Patching: Why Dependabot Was a Week Late
If your storefront runs Next.js, check two version numbers today. next needs to be at least 16.4.1 (or 15.5.28 if you are still on 15.x), and the sharp package that Next.js uses for image optimization needs to be at least 0.35.5. Vercel shipped the fixes for two critical remote code execution advisories on October 14, 2026, with release notes that named them. The GitHub Advisory Database, which drives Dependabot alerts, did not list them until October 22. In npm's per-version download counts pulled on October 26, 69% of next downloads were still versions inside the affected ranges.
Key takeaways
- Two critical, unauthenticated RCE advisories (GHSA-673q-mjm6-r5xr and GHSA-2464-fhr4-w9xw) cover Next.js 16.0.0 to 16.4.0, and the image one also covers 10.0.0 to 15.5.27.
- Only 30.7% of last week's 46.8 million
nextdownloads were patched releases. - For all 20 critical and high Next.js advisories published in 2026, the database entry trailed Vercel's own advisory by a median of 4.9 days. For the five criticals the gap was 7.9 to 14.2 days.
- In our test, upgrading a locked 15.5.27 project to 15.5.28 left
sharpat the vulnerable 0.34.5, andnpm audit --audit-level=criticalstill passed. - Next.js 14.x is unsupported and has no patched release for this year's image optimizer RCEs. It still drew 5.3% of downloads.

What did Vercel fix on October 14?
Vercel fixed two critical RCEs and one high-severity denial of service in Next.js 16.4.1 and 15.5.28, both published to npm on October 14, 2026. The advisories are specific about who is exposed, so read the conditions before you triage:
| Advisory | Severity | Exposed when (per the advisory) | First fixed |
|---|---|---|---|
| GHSA-673q-mjm6-r5xr | Critical, RCE | App Router with Cache Components and a use cache function that returns multiple typed arrays. No workaround; Vercel says to upgrade even if you have no such function. | 16.4.1 |
| GHSA-2464-fhr4-w9xw | Critical, RCE | Image Optimization with SVG files, on glibc-based Linux. The bug is in an upstream library; the fix needs sharp 0.35.5 or later. | 15.5.28, 16.4.1 |
| GHSA-p3m5-59mp-jv5r | High, DoS | App Router with at least one Server Action. Pages Router apps are not affected. | 15.5.28, 16.4.1 |
The image advisory is the one most storefront teams should check first, because product media usually flows through next/image. The upstream issue is CVE-2026-96889 in librsvg, which sharp's own advisory marks as affecting every sharp release below 0.35.5.
How many Next.js installs are still on affected versions?
Most of them. We matched npm's per-version download counts for next (the last seven days, as reported on October 26) against every advisory range in the GitHub Advisory Database:
| Group | Downloads | Share |
|---|---|---|
| Patched (16.4.1 or later, 15.5.28 or later) | 14,376,578 | 30.7% |
| Inside the October 22 critical ranges | 32,253,249 | 69.0% |
| On a version with a critical advisory listed by September 30 | 19,634,880 | 42.0% |
| Unsupported majors (14.x and older) | 3,092,780 | 6.6% |
| Single most downloaded unpatched release: 16.3.8 | 6,252,963 | 13.4% |
Downloads are not deployments. CI pipelines and fresh installs inflate the count, while cached builds never show up in it. npm's documentation does not define what counts as a download for this endpoint. Treat the table as a direction, not a census. The direction is clear, though: three weeks or more after the September criticals were listed, two in five downloads still fell inside their ranges.
Why did Dependabot stay quiet for a week?
Because Dependabot reads the GitHub Advisory Database, and Next.js advisories reached it days after Vercel published them in its own repository and shipped the fix. GitHub's documentation says Dependabot alerts come from GitHub-reviewed advisories, and unreviewed advisories never create alerts. In our test below, every finding npm audit printed linked to a github.com/advisories entry as well.
Here is the gap for each critical Next.js advisory of 2026. The repository date is when Vercel published the advisory on vercel/next.js; the database date is when it appeared in the GitHub Advisory Database:
| Advisory | Fix on npm | Repository advisory | Database entry | Gap |
|---|---|---|---|---|
| GHSA-p293-qw3h-jr36, RCE on Windows hosts | Aug 25 | Aug 25 | Sep 8 | 14.2 days |
| GHSA-2xp9-vwfh-vxw4, RCE via AVIF images | Aug 25 | Aug 25 | Sep 8 | 14.2 days |
| GHSA-vcvr-r3jv-pc5j, RCE in next/og ImageResponse | Sep 22 | Sep 22 | Sep 30 | 7.9 days |
| GHSA-2464-fhr4-w9xw, RCE via SVG images | Oct 14 | Oct 14 | Oct 22 | 7.9 days |
GHSA-673q-mjm6-r5xr, RCE in use cache | Oct 14 | Oct 14 | Oct 22 | 8.0 days |
Across all 20 critical and high advisories this year the median gap was 4.9 days and the shortest was 1.3 days. Each critical fix was on npm within an hour of Vercel's advisory, and the 16.4.1 release notes named both criticals on October 14. A team that watches the vercel/next.js releases feed had the information eight days before a team that waits for a Dependabot pull request.
Does upgrading next also fix the image optimizer?
Not always. On the 15.x line, a lockfile can keep the vulnerable sharp after you upgrade next. We tested it with npm 10.9.4 and Node.js 22.22.0:
- A project on
next@15.5.27withsharp@0.34.5in its lockfile.npm install next@15.5.28finished cleanly, andnpm ls sharpstill showed 0.34.5. The reason is in the package: 15.5.28 declaressharpas^0.34.3 || ^0.35.5, and 0.34.5 satisfies the first half of that range. - On that same project,
npm audit --omit=devreported thesharpadvisories as high, not critical. Sonpm audit --audit-level=criticalexited 0, and a CI gate set to critical would have passed the build. npm update sharpmoved it to 0.35.5 and cleared thesharpfindings. On 15.5.28, npm audit still reports one high advisory throughpostcss, and the fix it offers is Next.js 16.4.3.- On 16.x the range is strict. 16.4.1 and later declare
^0.35.5, so upgrading a project from 16.4.0 (locked tosharp@0.35.4) to 16.4.3 movedsharpto 0.35.5 on its own, and npm audit found nothing.
Run this after every Next.js upgrade:
npm ls next sharp
npm audit --omit=dev --audit-level=highVersion floors also belong in CI, so a stale lockfile cannot ship. This script (an ES module with no dependencies, tested on Node.js 22.22.0) fails the build when next or the sharp it resolves is below the October 2026 fixes. We ran it against four test projects: it failed the locked 15.5.28 project and a 14.2.35 project, and passed 15.5.28 with sharp 0.35.5 and 16.4.3.
// check-next-patch.mjs
// Fails the build when next or sharp is below the October 2026 security floor.
import { createRequire } from "node:module";
import { existsSync, readFileSync } from "node:fs";
import { dirname, join } from "node:path";
const require = createRequire(import.meta.url);
const FLOOR = { 15: "15.5.28", 16: "16.4.1" }; // next major -> first patched release
const SHARP_FLOOR = "0.35.5";
const parse = (v) => v.split("-")[0].split(".").map(Number);
const below = (a, b) => {
const [x, y] = [parse(a), parse(b)];
for (let i = 0; i < 3; i++) if (x[i] !== y[i]) return x[i] < y[i];
return false;
};
// Walk up from the resolved entry file, since some packages do not export package.json.
const installed = (name, from) => {
try {
let dir = dirname(require.resolve(name, from ? { paths: [from] } : undefined));
while (dir !== dirname(dir)) {
const file = join(dir, "package.json");
if (existsSync(file)) {
const pkg = JSON.parse(readFileSync(file, "utf8"));
if (pkg.name === name) return pkg.version;
}
dir = dirname(dir);
}
} catch {}
return null;
};
const next = installed("next");
const sharp = installed("sharp", dirname(require.resolve("next")));
const errors = [];
const floor = next && FLOOR[parse(next)[0]];
if (!next) errors.push("next is not installed");
else if (!floor) errors.push(`next ${next} is on an unsupported major`);
else if (below(next, floor)) errors.push(`next ${next} is below ${floor}`);
if (sharp && below(sharp, SHARP_FLOOR)) errors.push(`sharp ${sharp} is below ${SHARP_FLOOR}`);
if (errors.length) {
console.error(errors.join("\n"));
process.exit(1);
}
console.log(`ok: next ${next}, sharp ${sharp ?? "not installed"}`);Add it as a prebuild script ("prebuild": "node check-next-patch.mjs") and raise the floors each time Vercel ships a security release.
Which Next.js versions still get security fixes?
Only 16.x and 15.x. The Next.js support policy lists 16.x as Active LTS, 15.x as Maintenance LTS (critical bug fixes and essential security updates only), and 14.x and older as unsupported. Two consequences for ecommerce teams:
- 14.x has no fix for this year's image optimizer RCEs. The newest 14.x release is 14.2.35 from December 11, 2025. The AVIF and SVG advisories both cover it, and their first patched releases are on 15.x (15.5.24 and 15.5.28). A 14.x store has to change majors to close them.
- 15.x is near the end of its window. The policy keeps a major in Maintenance LTS for two years after its initial release. Next.js 15.0.0 shipped October 21, 2024, so by that rule 15.x reached the two-year mark this month, although the support page still listed it as Maintenance LTS on October 26. If you run 15.x, put the move to 16 on this quarter's roadmap rather than the next one.
The pace has also picked up. By database publication date, Next.js had 5 critical and 15 high advisories in 2026 so far, against 2 critical and 3 high in all of 2025. We covered the release-cadence side of this in our Next.js vs Gatsby release data; the security side says the same thing: a Next.js storefront is a living dependency, not a one-time build.
What patch process should an ecommerce team run?
Measure your patch window from Vercel's release, not from the Dependabot alert. In 2026 that difference was at least 7.9 days for every critical. The process we recommend:
- Watch the source. Subscribe to releases on the vercel/next.js repository. Security releases name their advisories in the notes, as 16.4.1 did.
- Gate CI at high, not critical. The
sharpadvisories behind a critical Next.js RCE were rated high. Runnpm audit --omit=dev --audit-level=highplus the floor script above. - Check what the lockfile resolved.
npm ls sharpafter everynextupgrade, especially on 15.x. - Keep a same-day path to production. A patch release that cannot reach production for two weeks because of a release freeze has the same exposure as no patch. Agree in advance that security releases bypass the freeze.
- Stay on a supported major. If you are on 14.x or older, the fix for this month's advisories is a migration, not an update.
What does it cost to keep a Next.js storefront patched?
We do not publish a fixed price, but it has to be a budgeted line, not a favor. Our Next.js maintenance plans (a monthly retainer or hourly) include Next.js and dependency upgrades plus security patches, and we give a fixed-scope estimate within 48 hours of a brief. A major-version move such as 14.x to 16.x is scoped per project. We made the same argument for Hydrogen in our cost-of-ownership check: maintenance belongs in the budget from day one. See the Next.js development page for how the plans work, or send us your package.json and we will tell you which advisories apply.
How we measured this
All data was pulled on October 26, 2026.
- Advisories: GitHub Advisory Database REST API, every advisory that lists the
nextnpm package, with withdrawn entries checked (none). Repository publication dates come from the vercel/next.js security advisories API. - Downloads: npm's
versions/next/last-weekendpoint, 46,767,618 downloads across 3,376 versions. Ranges were matched with a semver comparison that handles prereleases. - Release dates: the npm registry
timefield fornextandsharp. - Lockfile test: fresh npm projects with
--ignore-scripts, npm 10.9.4, Node.js 22.22.0. - Limits: download counts are not deployments, and an affected version is not automatically exploitable. Each advisory lists the conditions it needs, and the table above repeats them.
Do you want secure, fast website or application?