# @astrojs/react

> Use React components within Astro

Latest version **6.0.5** (published 2026-08-31) · MIT license · 0 weekly downloads

## Install

```sh
npm install @astrojs/react
pnpm add @astrojs/react
yarn add @astrojs/react
bun add @astrojs/react
```

## Health

**Score 75/100 (B)** — status: active.

Positive: esm support; no vulnerabilities; has provenance; recently updated; high maintenance score; popular repo; extremely popular.

Warnings: low downloads; no types.

## Facts

| | |
|---|---|
| Version | 6.0.5 |
| Published | 2026-08-31 |
| First published | 2022-03-18 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM |
| Node | >=22.12.0 |
| Dependencies | 5 |
| Unpacked size | 33.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| GitHub stars | 62448 |
| Author | withastro |
| Maintainers | fredkschott, matthewp |
| Keywords | astro-integration, astro-component, renderer, react |

## Links

- npm: https://www.npmjs.com/package/@astrojs/react
- Repository: https://github.com/withastro/astro
- Homepage: https://docs.astro.build/en/guides/integrations-guide/react/
- Issues: https://github.com/withastro/astro/issues
- npm.io page: https://npm.io/package/@astrojs/react

## Dependencies (5)

- [vite](https://npm.io/package/vite.md) ^8.0.13
- [devalue](https://npm.io/package/devalue.md) ^5.8.1
- [ultrahtml](https://npm.io/package/ultrahtml.md) ^1.6.0
- [@vitejs/plugin-react](https://npm.io/package/@vitejs/plugin-react.md) ^5.2.0
- [@astrojs/internal-helpers](https://npm.io/package/@astrojs/internal-helpers.md) 0.11.0

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 6.0.5 (latest) — 2026-08-31
- 6.0.0-beta.2 (beta) — 2026-06-18
- 6.0.0-alpha.0 (alpha) — 2026-04-30
- 0.0.0-router-noexec-20250129135648 (experimental--router-noexec) — 2025-01-29
- 0.0.0-atomic-writes-20241212091949 (experimental--atomic-writes) — 2024-12-12
- 0.0.0-sessions-20241128172109 (experimental--sessions) — 2024-11-28
- 0.0.0-experimental-container-20240613104104 (experimental--experimental-container) — 2024-06-13
- 0.0.0-container-20240524172326 (experimental--container) — 2024-05-24
- 0.0.0-astro-env-20240522153443 (experimental--astro-env) — 2024-05-22
- 0.0.0-react-19-20240503180451 (experimental--react-19) — 2024-05-03
- 0.0.0-cc-preserve-cache-20240502141405 (experimental--cc-preserve-cache) — 2024-05-02
- 0.0.0-10745-20240410180016 (experimental--10745) — 2024-04-10
- 0.0.0-toolbar-improvements-20240405144822 (experimental--toolbar-improvements) — 2024-04-05
- 0.0.0-non-admin-test-20240308195029 (experimental--non-admin-test) — 2024-03-08
- 0.0.0-dupicate-content-entry-improved-message-20231220220040 (experimental--dupicate-content-entry-improved-message) — 2023-12-20
- … 148 more at https://npm.io/package/@astrojs/react/versions

## README

# @astrojs/react ⚛️

This **[Astro integration][astro-integration]** enables server-side rendering and client-side hydration for your [React](https://react.dev/) components.

## Documentation

Read the [`@astrojs/react` docs][docs]

## Support

- Get help in the [Astro Discord][discord]. Post questions in our `#support` forum, or visit our dedicated `#dev` channel to discuss current development and more!

- Check our [Astro Integration Documentation][astro-integration] for more on integrations.

- Submit bug reports and feature requests as [GitHub issues][issues].

## Contributing

This package is maintained by Astro's Core team. You're welcome to submit an issue or PR! These links will help you get started:

- [Contributor Manual][contributing]
- [Code of Conduct][coc]
- [Community Guide][community]

## License

MIT

Copyright (c) 2023–present [Astro][astro]

[astro]: https://astro.build/
[docs]: https://docs.astro.build/en/guides/integrations-guide/react/
[contributing]: https://github.com/withastro/astro/blob/main/CONTRIBUTING.md
[coc]: https://github.com/withastro/.github/blob/main/CODE_OF_CONDUCT.md
[community]: https://github.com/withastro/.github/blob/main/COMMUNITY_GUIDE.md
[discord]: https://astro.build/chat/
[issues]: https://github.com/withastro/astro/issues
[astro-integration]: https://docs.astro.build/en/guides/integrations/

---
_Source: https://npm.io/package/@astrojs/react · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
