Skip to content

Unable to install react-helmet-async in React 19 #238

Closed

Description

@starxyn

Is react-helmet-async compatible with React 19?

I see that the version is react@"^16.6.0 || ^17.0.0 || ^18.0.0" only

Activity

  1. DanielSchiavini commented on Dec 20, 2024

    @DanielSchiavini
  2. slorber commented on Dec 30, 2024

    @slorber
    Contributor

    We might not need it anymore: react.dev/blog/2024/12/05/react-19#support-for-metadata-tags

    This library covers more than what React 19 offers currently: #239 (comment)

  3. imkss commented on Apr 10, 2025

    @imkss

    Do we really need react-helmet-async in react 19?
    https://egghead.io/hoist-title-and-meta-tags-in-react-19~h6z5l

  4. slorber commented on Apr 10, 2025

    @slorber
    Contributor

    Do we really need react-helmet-async in react 19? https://egghead.io/hoist-title-and-meta-tags-in-react-19~h6z5l

    Again, yes, React 19 features do not cover everything

    #239 (comment)

  5. mbdev3 commented on Apr 15, 2025

    @mbdev3

    For those getting a warning or don't want to everytime run an npm i --force add this to package.json:

    "overrides": { "react-helmet-async": { "react": "^19.0.0", "react-dom": "^19.0.0" } }

  6. swapnilahmedshishir commented on Apr 17, 2025

    @swapnilahmedshishir

    Option 1: Use --legacy-peer-deps (recommended for now)
    This tells npm to install it anyway and ignore the peer conflict:

    npm install react-helmet-async --legacy-peer-deps

    ✅ Works in most cases if the package still functions fine under React 19 (which it probably does unless there are breaking changes).

    Option 2: Use --force (riskier)

    npm install react-helmet-async --force

    This forces npm to install it no matter what. But be careful — this can break stuff if the library really isn't compatible.

  7. AchmetCh commented on Jun 4, 2025

    @AchmetCh

    I installed react-helmet with npm install react-helmet-async --legacy-peer-deps
    Is there a way to test my metadata on localhost?
    cause i don't see on any component any of my metadata.
    Is the legacy-peer-deps the correct way?
    thanks!

  8. Rupon100 commented on Aug 31, 2025

    @Rupon100

    but peer dependency warnings will show in the console

  9. staylor commented on Mar 6, 2026

    @staylor
    Owner
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions