unstale

npm / @fastify/cors

@fastify/cors

What changed in @fastify/cors 9 to 11, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-30.

1 breaking1 security1 new APIs and options1 behavior and defaults3 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli on npm

@fastify/cors 116 changes

Breaking changes 1

  • The default methods changed to CORS-safelisted methods; specify methods explicitly to resume the previous behavior.

    11.0.0release notes

Security 1

  • Fixes a security issue identified in GHSA-8c3j-mm64-257c.

    11.4.0release notes

New APIs and options 1

  • Route-level CORS configuration is now supported, allowing CORS settings to be specified for individual routes.

    11.2.0release notes

Fixes and other changes 3

  • An origin array containing '*' from a dynamic resolver or route-level config.cors now responds with Access-Control-Allow-Origin: *, matching the static origin: ['*'] option.

    11.4.3release notes

  • Origin resolution is skipped when a route disables CORS.

    11.4.2release notes

  • The vary parser preserves header tokens with whitespace preceding commas.

    11.4.1release notes

@fastify/cors 91 changes

Behavior and default changes 1

  • The Vary header is added only when the origin option is non-static.

    9.0.0release notes