1. License
“to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge,”
MIT allows use in paid and closed-source products; the built files are your code.
github.com/vitejs/vite/blob/main/LICENSE3. Used by agents' projects
Dependency in 1,238 public GitHub projects set up for AI coding agents that we scanned (19.8%).
4. Agent access
Agent skills for this library in the skills catalog; community skills are written by others, read them before you install.
vite.dev/llms.txtFrom the package registry and GitHub, checked daily; card checked Nov 10, 2026. Tap a verdict to see its source.How we checkedReport an error
What Vite does
Vite is a free tool that runs your web app on your own computer while you build it, and packs it into fast files when you publish. Each time you save, the change shows in the browser at once. It comes with starter templates for React, Vue, Svelte and others.
What people build with it
Start a new app from a template
Your assistant creates a ready React, Vue, Svelte or plain TypeScript project in one command and starts it.
See changes the moment you save
While you or your assistant edit a page, the open browser tab updates on save, without a full reload in most cases.
Publish as plain files
One command makes a dist folder of small files you can upload to any static host, and a second one lets you check them first.
Settings that may reach the browser
Public settings like a site name go into .env with a VITE_ prefix; anything without the prefix stays out of the browser.
A site that lives in a sub-folder
When the app runs at example.com/shop/ instead of the main address, all links to scripts, styles and pictures are fixed for that folder.
Modern front-end for a Laravel or Rails site
Keep pages made by your existing server and let Vite handle the scripts and styles, with instant updates while you work.
Vite popularity
Gid Score measures public popularity and activity, not quality. How the Gid Score is calculated
How Vite is used
- Vite is a dependency in 1,238 of the 6,258 public GitHub projects set up for AI coding agents that we scanned (25.4% of the 4,867 JavaScript/TypeScript ones), #1 of 185 in build tools and bundlers.
- Counting the projects our scan samples by dependency (Solana 3,067, Ethereum and EVM 1,774, 3D and games 3,130, agent frameworks and SDKs 13,750), it appears in 4,635; those are left out of every share on this page.
- The most used alternative in our scan is SWC (110 projects).
- Projects that use it most often also use Tailwind CSS (72.4%), Vitest (53.5%), React (66.7%).
- It is more common in projects set up for Junie (68.9%) than for GitHub Copilot (18.1%).
By coding agent
Often used with
Vite in practice
Strengths
Source files are served over native ESM, and the browser loads only what the current page needs. The Why Vite page says that when Vite was first created, this split made dev server startup "nearly instant, regardless of application size". On edit, HMR updates just the changed module without a full page reload.
Vite used to run esbuild in dev and Rollup in build. The maintainers write that the two pipelines behaved differently and needed glue code. Rolldown is written in Rust and uses Oxc. It was built to unify both into a single bundler with the same plugin API.
The site says Vite plugins extend Rollup's plugin interface with a few Vite-specific options. It also says the API is fully typed and "Designed to be built on top of."
The team runs vite-ecosystem-ci, which tests major ecosystem projects against each Vite change. The maintainers call ecosystem health "part of the release process".
Watch out for
Vite sets <code>esnext</code> as the dev transform target and does no syntax lowering. Production builds target Baseline Widely Available browsers, which for this major means browser versions released around mid-2023. Older browsers need a lowered target or <code>@vitejs/plugin-legacy</code>.
The docs require Node.js 20.19+ or 22.12+. Some templates need a newer version than that.
The maintainers write that exceptionally large codebases can see slow page loads because of the number of unbundled requests. A full bundle mode for the dev server is described as something the team is exploring.
Default npm scripts in a scaffolded project
{
"scripts" : {
"dev" : "vite" , // start dev server, aliases: `vite dev`, `vite serve`
"build" : "vite build" , // build for production
"preview" : "vite preview" // locally preview production build
}
}More about Vite
Funding
- GitHub Sponsors: https://github.com/vitejs
- Open Collective: https://opencollective.com/vite
- Own page: https://github.com/vitejs/vite?sponsor=1
- 44 GitHub sponsors
Agent Skills for it
- vite: Expert guidance for Vite development with modern build tooling, HMR, framework integrations, and performance optimization
- vite: Vite build tool configuration, plugin API, SSR, and Vite 8 Rolldown migration. Use when working with Vite projects, vite.config.ts, Vite plu
- vite: Vite build tool configuration, plugin API, SSR, and Vite 8 Rolldown migration. Use when working with Vite projects, vite.config.ts, Vite plu
Head to head
- Vite vs webpack used together in 13 projects
Packages around it
- @vitejs/plugin-react: Official React plugin
- @vitejs/plugin-react-swc: React plugin using SWC
- @vitejs/plugin-vue: Official Vue SFC plugin
- @vitejs/plugin-vue-jsx: Vue JSX support
- @vitejs/plugin-basic-ssl: Self-signed HTTPS for dev
- @vitejs/plugin-legacy: Legacy browser support
More in Build tools and bundlers
Alternatives
Vite This page
Pick esbuild when you only need a fast bundling or minify step for scripts, not a whole dev setup.
Pick webpack when a project already relies on its configuration and loaders.
Pick Parcel when you want a bundler that works with no configuration file at all.
Super-fast Rust-based JavaScript compiler and bundler alternative to Babel.
Get started
Tell your AI assistant
“Create a React + TypeScript app with Vite 8 (vite 8.3.7, Node 20.19+ or 22.12+), keep secrets out of VITE_ variables, and add a type check (tsc --noEmit) before vite build.”
Or add Vite to an existing folder that has an index.html and run it.
npm install -D vite npx viteFrom vite.dev/guide/
Rules for your agent
## Vite
- Scaffold with `npm create vite@latest my-app -- --template <name>`. With npm 7+, the extra `--` is needed. Add `--no-interactive` to skip the prompts.
- Use the standard scripts: `vite` for dev, `vite build` for production, and `vite preview` to check the build locally.
- Keep `vite.config.js` in the project root. If you change the root with `vite serve some/sub/dir`, move the config file there too.
- Write explicit import paths such as `import './Component.jsx'`. With TypeScript, set `"moduleResolution": "bundler"` and `"allowImportingTsExtensions": true`.
- Avoid barrel files. Import directly instead, for example `import { slash } from './utils/slash.js'`.
- Only add files to `server.warmup` if they are frequently used. Keep the `buildStart`, `config` and `configResolved` plugin hooks short.
- For older browsers, lower the build target or add `@vitejs/plugin-legacy`. To replace the Vite version used by dependencies, use npm or pnpm overrides.
Mistakes to avoid
Every VITE_ value is copied into the public JavaScript files at build time.
vite preview is only for checking the build on your own machine.
Vite strips types file by file and never checks them.
In Vite 8 the esbuild options are only converted for backward compatibility and are deprecated.
Vite reads .env files once, at start.
Questions
Can I use it for a paid product?
Yes. Vite is MIT-licensed.
Can I put my secret keys in .env?
Yes, but never with the VITE_ prefix. VITE_ values are written into the public files; keep secrets on a server.
Is vite preview a production server?
No. It only lets you look at the built files on your own computer. Upload dist/ to a host instead.
What changed in Vite 8?
It now uses Rolldown and Oxc instead of esbuild and Rollup. Old esbuild settings still work for now but are deprecated.
I changed .env and nothing happened. Why?
Vite reads .env files only when it starts. Restart the dev server.