Packages

astro

7.4.13 · 18 Nov 2026MIT12.5M / weekRepositoryHomepagenpmAtom feed

Upgrading astro From 4.16.19 to 5.0.0

1 release in betweenevery note read

Other targets from 4.16.19Clears its 20 advisories7.4.5Latest7.4.13
  1. 4.16.19yours
  2. 5.0.0target

Start here

Before you upgrade

Tick each one off as you go
  • Breaking5.0.0
  • Breaking5.0.0
  • Breaking5.0.0
  • Breaking5.0.0
  • Breaking5.0.0
  • Breaking5.0.0
  • Breaking5.0.0
  • Breaking5.0.0
  • Breaking5.0.0
  • Breaking5.0.0

Security

  • Updates the default value of security.checkOrigin to true, which enables Cross-Site Request Forgery (CSRF) protection by default for pages rendered on demand.

    5.0.0
  • Changes the generated URL query param from _astroAction to _action when submitting a form using Actions. This avoids leaking the framework name into the URL bar, which may be considered a security issue.

    5.0.0

Release by release

  1. 5.0.0

    Security fix3 Dec 202419 new · 36 fixes
    • Security

      Updates the default value of security.checkOrigin to true, which enables Cross-Site Request Forgery (CSRF) protection by default for pages rendered on demand.

    • Security

      Changes the generated URL query param from _astroAction to _action when submitting a form using Actions. This avoids leaking the framework name into the URL bar, which may be considered a security issue.

    • Breaking

      Unflag globalRoutePriority

    • Breaking
12 other lines we could not sort, mostly version bumps
  • vfile.data.__astroHeadings -> vfile.data.astro.headings

    5.0.0
  • vfile.data.imagePaths -> vfile.data.astro.imagePaths

    5.0.0
  • AstroRenderer.clientEntrpoint

    5.0.0
  • AstroRenderer.serverEntrypoint

    5.0.0
  • ViewTransitions component renamed to ClientRouter

    5.0.0
  • The value of the different properties on supportedAstroFeatures for adapters can now be objects, with a support and message properties. The content of the message property will be shown in the Astro CLI when the adapter is not compatible with the feature, allowing one to give a better informational message to the user.

    5.0.0
  • astro add no longer automatically sets output: 'server'. Since the default value of output now allows for server-rendered pages, it no longer makes sense to default to full server builds when you add an adapter

    5.0.0
  • Server Islands introduced behind an experimental flag in v4.12.0 is no longer experimental and is available for general use.

    5.0.0
  • Changes the default behavior for Astro Action form requests to a standard POST submission.

    5.0.0
  • Changes the default content config location from src/content/config.* to src/content.config.*.

    5.0.0

3 internal lines (docs, tests, tooling) left out.

A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.