Skip to content
PluginStats

@vitejs/plugin-react weekly downloads statistics

By vitejs (9 listings) · npm · Vite plugins

The default Vite plugin for React projects

View on npm Fresh · Oct 17, 2026

@vitejs/plugin-react has 48,114,108 recorded weekly downloads on npm, a decrease of 41.3% over the past 30 days.

It ranks #5 of 2,256 tracked npm listings by weekly downloads.

Over 90 days, weekly downloads changed by -36.3%.

PluginStats has 121 daily observations since Jun 19, 2026; the latest is from Oct 17, 2026.

Weekly downloads
48,114,108
Official API · Oct 17, 2026
7-day growth
-50.5%
-49.1M weekly downloads
30-day growth
-41.3%
-33.9M weekly downloads
90-day growth
-36.3%
-27.4M weekly downloads
Rank
#5
Among tracked npm listings

About @vitejs/plugin-react

@vitejs/plugin-react

The default Vite plugin for React projects.

• enable Fast Refresh in development (requires react >= 16.9) • use the automatic JSX runtime • small installation size

Options

include

Includes .js, .jsx, .ts & .tsx by default. This option can be used to add fast refresh to .mdx files:

exclude

The default value is /node_modules/. You may use it to exclude JSX/TSX files that runs in a worker or are not React files. Except if explicitly desired, you should keep node_modules in the exclude list:

jsxImportSource

Control where the JSX factory is imported from. By default, this is inferred from jsxImportSource from corresponding a tsconfig file for a transformed file.

jsxRuntime

By default, the plugin uses the automatic JSX runtime. However, if you encounter any issues, you may opt out using the jsxRuntime option.

reactRefreshHost

The reactRefreshHost option is only necessary in a module federation context. It enables HMR to work between a remote & host application. In your remote Vite config, you would add your host origin:

Under the hood, this simply updates the React Fash Refresh runtime URL from /@react-refresh to http://localhost:3000/@react-refresh to ensure there is only one Refresh runtime across the whole application. Note that if you define base option in the host application, you need to include it in the option, like: http://localhost:3000/{base}.

React Compiler

Rust React Compiler

[!WARNING] Native React Compiler support is experimental.

The compiler option uses oxc-transform-react, a Rust port of React Compiler, which must be installed as an optional peer dependency:

The compiler option also accepts React Compiler options:

Set logDiagnostics to true to log recoverable React Compiler diagnostics through Vite. This option defaults to false. Fatal diagnostics are always logged and fail the transform.

Babel React Compiler

React Compiler can also be used through Babel with the exported reactCompilerPreset helper. This requires @rolldown/plugin-babel, babel-plugin-react-compiler, and @babel/core as peer dependencies:

If you are using TypeScript with Babel 7, you will also need to install @types/babel__core:

The reactCompilerPreset accepts an optional options object with the following properties:

• compilationMode — Set to 'annotation' to only compile components annotated with "use memo". • target — Set to '17' or '18' to target older React versions (uses react-compiler-runtime instead of react/compiler-runtime).

Additional options can be found in the documentation.

[!TIP]

reactCompilerPreset is only a convenient helper with a preconfigured filter. You can configure override the filters to fit your project structure or code. For example, if you know a large portion of your files are never React/hook-related or won't benefit from the React Compiler, you can aggressively exclude them via rolldown.filter:

@vitejs/plugin-react/preamble

The package provides @vitejs/plugin-react/preamble to initialize HMR runtime from client entrypoint for SSR applications which don't use transformIndexHtml API. For example:

Alternatively, you can manually call transformIndexHtml during SSR, which sets up equivalent initialization code. Here's an example for an Express server:

Otherwise, you'll get the following error:

Consistent components exports

For React refresh to work correctly, your file should only export React components. You can find a good explanation in the Gatsby docs.

If an incompatible change in exports is found, the module will be invalidated and HMR will propagate. To make it easier to export simple constants alongside your component, the module is only invalidated when their value changes.

You can catch mistakes and get more detailed warnings with this ESLint rule, this Oxlint rule, or this Biome rule.

Description from the npm listing.

  • fast refresh
  • react
  • react-refresh
  • vite
  • vite-plugin

Where @vitejs/plugin-react sits in the listing

Each band is one page of 20. Weekly downloads on a log scale. Placement is projected from weekly downloads, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.

All npm2,256 listings · 113 pages · page 1, #5 (overall #5)
All npm: every listing in weekly downloads order
PNG SVG
Vite plugins250 listings · 13 pages · page 1, #1 (overall #1)
Vite plugins: every listing in weekly downloads order
PNG SVG

Charts

Images: 30d · 1y · all time · 1600×900 dark

Adoption over time

@vitejs/plugin-react weekly downloads on npm, last 90 days: 48,114,108 weekly downloads as of Oct 17, 2026, -36.3% over 90 days.@vitejs/plugin-reactWeekly downloads on npm · Last 90 days48,114,108downloads / week-36.3% over 90 days40M50M60M70M80M90M100M110M120MJul 19Aug 3Aug 18Sep 2Sep 17Oct 2Oct 17downloads / weekobservedarchived (Internet Archive)no observationsJul 21, 2026 – Oct 17, 2026 · 89 observations · Updated Oc…pluginstats.com
@vitejs/plugin-react weekly downloads on npm, last 90 days: 48,114,108 weekly downloads as of Oct 17, 2026, -36.3% over 90 days.
PNG SVG

7/30/90-day growth

@vitejs/plugin-react weekly downloads growth on npm: -50.5% over 7 days, -41.3% over 30 days, -36.3% over 90 days.@vitejs/plugin-reactWeekly downloads growth on npm48,114,108downloads / week now7-day growth-49,094,211 weekly downl…-50.5%30-day growth-33,853,526 weekly downl…-41.3%90-day growth-27,406,779 weekly downl…-36.3%Growth vs. nearest observation to each baseline date · Updated Oct 17, 2026pluginstats.com
@vitejs/plugin-react weekly downloads growth on npm: -50.5% over 7 days, -41.3% over 30 days, -36.3% over 90 days.
PNG SVG

Ranking history

@vitejs/plugin-react npm ranking history: currently #5 (by weekly downloads).@vitejs/plugin-reactnpm ranking · by weekly downloads · Last 90 days#5current rank#3#4#5#6#7Jul 21Aug 5Aug 20Sep 4Sep 19Oct 4Oct 19rankOct 18, 2026 – Oct 19, 2026 · 2 observations · Updated Oct 17, 2026pluginstats.com
@vitejs/plugin-react npm ranking history: currently #5 (by weekly downloads).
PNG SVG

Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.

Recent observations

Full history (121)
Recent weekly downloads observations for @vitejs/plugin-react
Date (UTC)Weekly downloadsChange vs. previous
48,114,108-11.8M
59,890,837+40.9K
59,849,922-19M
78,845,094-17.9M
96,704,4630
96,704,463-570.7K
97,275,135+66.8K
97,208,319-72K
97,280,306+729.9K
96,550,456-699.9K
97,250,325-761.1K
98,011,408-18.9M
116,894,835-24.3K
116,919,148—

Similar npm Vite plugins plugins

Data source

Weekly downloads (trailing 7 complete days) come from the official npm downloads API. Downloads include CI and mirrors and are not equivalent to installs or users. npm publishes no ratings.

Listing: https://www.npmjs.com/package/@vitejs/plugin-react. First seen Oct 16, 2026; last successful collection Oct 19, 2026. See the methodology.