Generate Vitest configuration files instantly. Customize test environment, coverage, TypeScript, aliases, and more. Export as TS, JS, or MJS.
Enter alias mappings, one per line (e.g. @/components => ./src/components)
Test file patterns, one per line
Patterns to exclude from test discovery
Vitest is a blazing fast unit test framework powered by Vite. It provides out-of-the-box support for TypeScript, JSX, and ESM, with instant feedback and intelligent watch mode. This generator creates ready-to-use Vitest configuration files tailored to your project type, saving you time and reducing setup friction. All generation happens client-side — no data is sent to any server.
Vitest is a fast Vite-powered unit testing framework. It offers instant feedback, intelligent watch mode, and native ESM support, making it a popular alternative to Jest for Vite-based projects.
v8 is faster and uses native Chrome coverage, but may be less accurate in some edge cases. istanbul is the traditional standard with broader ecosystem support. For most projects, v8 is sufficient and faster.
jsdom is the standard browser environment emulator used by Jest. happy-dom is a lighter, faster alternative that implements many browser APIs with better performance. Choose happy-dom for speed, jsdom for maximum compatibility.
Enabling globals lets you use describe, it, expect without importing them. This matches Jest behavior and is convenient, but explicit imports are recommended for better TypeScript support and clarity.
threads (default) runs tests in worker threads with good performance. forks creates isolated Node.js processes for maximum isolation. vmThreads uses VM contexts (experimental). Use threads for most projects, forks if you encounter module isolation issues.
Select your project preset, enable globals for Jest-compatible API, and choose the same test environment (jsdom/node). Most Jest APIs are compatible with Vitest. Update your package.json scripts to use vitest instead of jest.
Yes! Vitest has native TypeScript support without requiring ts-jest or babel-jest. Just use .ts or .tsx test files and Vitest handles compilation automatically via Vite.
Yes, Vitest can be used independently of Vite. It uses Vite under the hood but works with any project. However, it shines brightest when paired with Vite for the most seamless experience.