All posts

Storybook’s dev-server flaw: can a website you visit edit your files?

CVE-2026-114125 (CVSS 9.4): a running Storybook dev server could be driven by a malicious website. Fixed in 8.6.19, 9.1.21 and 10.6.2. Who is affected, and what to do.

Published
Reading time
6 min
By
Girish Babu GV

What happened#

Storybook is a widely used tool for building and previewing UI components. The advisory was published on 12 October 2026 and updated on 21 October. The registry shows the patched storybook releases (8.6.19, 9.1.21 and 10.6.2) published on 12 October.

The advisory’s description: the Storybook preview lacks origin validation, so a malicious website can interact with a running dev server. With user interaction, that can make unauthorised changes to story files, and if a changed file is later run by a local runtime, the result could be code execution with the developer’s privileges. It lists a long set of weakness classes (CWE-22, 94, 96, 346, 441, 749, 862 and 1021) and credits a reporter called agent-killjoy.

The advisory states that the team is not aware of exploitation in the wild, and has not received evidence of exploitation in real Storybook projects. It gives an EPSS score of 0.385%, the 33rd percentile.

Am I affected?#

The advisory is specific about who is and isn’t affected:

  • Affected: you run a Storybook dev server on an affected version and open it in a browser.
  • Not affected: you only run the dev server headlessly (for example from automation or MCP clients), or you only run or visit a built Storybook.
Affected and patched versions, as listed in the advisory
PackageAffectedPatched
storybook8.x before 8.6.19; 9.x before 9.1.21; 10.x before 10.6.2; 11.0.0-alpha before alpha.68.6.19, 9.1.21, 10.6.2, 11.0.0-alpha.6
@storybook/core8.0.0 up to but not including 8.6.198.6.19
@storybook/core-server8.0.0 up to but not including 8.6.198.6.19
@storybook/experimental-addon-test8.0.0 up to but not including 8.6.198.6.19
@storybook/addon-vitest9.0.0 up to 9.1.21; 10.0.0 up to 10.6.2; 11.0.0-alpha before alpha.69.1.21, 10.6.2, 11.0.0-alpha.6
@storybook/addon-mcp10.6.0 up to 10.6.2; 11.0.0-alpha before alpha.610.6.2, 11.0.0-alpha.6

Storybook 7 and earlier do not appear in the advisory’s list of affected ranges. That is what the list says; it does not say whether older lines have a separate problem.

What to do now#

  1. Find your version. Run the commands below in every project that has Storybook, including monorepo packages.
  2. Upgrade before you next run storybook dev. Pick the patched release for your major line. If you can’t upgrade, the advisory says to avoid running an affected dev server.
  3. Don’t grant “connect to localhost” permission to sites you don’t trust. The advisory notes that Chrome and Firefox may prompt for this, which lowers the risk but does not remove it.
  4. Update Chromatic’s Visual Tests addon to 5.5.1 or later if you use it, because the advisory says the older version’s documentation link stops working otherwise.
Check, then update
# Which Storybook packages and versions do you have?
npm ls storybook @storybook/core @storybook/core-server

# Upgrade the Storybook packages together (pick your major line)
npx storybook@8.6.19 upgrade     # 8.x
npx storybook@9.1.21 upgrade     # 9.x
npx storybook@10.6.2 upgrade     # 10.x, or later 10.x

The upgrade commands use the Storybook CLI’s own upgrade command; check Storybook’s documentation for the current form for your package manager before running it.

What changes after upgrading#

The advisory lists behaviour changes that can break existing setups, so test your Storybook after the upgrade:

  • Embedding the preview in an iframe from a different hostname is disabled by default. The security.insecureRemoteIframeEmbed flag re-enables it.
  • The preview and manager exchange postMessage messages only with their own origin and localhost in dev mode. The security.insecureIframeMessaging flag turns that off, but the advisory recommends building composed Storybooks instead.
  • The highlight event signature changed, and there is no flag to restore the old one. Separately, Chromatic’s Visual Tests addon needs 5.5.1 or later.

The names of the two flags include “insecure” on purpose. I would leave both off unless you have a concrete need.

How I checked this site#

This site is a Next.js project on Vercel. I searched its package.json and package-lock.json for storybook and found no match, so it does not use Storybook. That covers this repository only.

What the sources don’t say#

  • Whether anyone has exploited it. The advisory says the team is not aware of exploitation, which is not proof there has been none.
  • How the attack works in detail. The advisory describes the outcome, not the steps, and I haven’t tried to reconstruct them.
  • Whether Storybook 7 and earlier are affected by a related issue. The advisory’s ranges start at 8.0.0.
  • I did not read independent coverage. My second source is the npm registry, for versions and dates.

My take#

My own opinion, not from the advisory.

A dev server feels private because it listens on localhost, but any page open in your browser can try to talk to it. Tools that can write files to your project are the ones where that matters most. The practical habits are cheap: keep dev tooling updated like any other dependency, don’t leave a dev server running while you browse unrelated sites, and treat a story file that changed when you didn’t change it as worth a look in git diff.

Sources#

Keep reading

Esc