Command Palette

Search for a command to run...

position in category
#4

Modular schema validation library for TypeScript that validates unknown data at runtime while preserving full type safety and static type inference. Designed for minimal bundle impact and developer experience, with zero dependencies and support for any JavaScript environment.

Valibot uses a modular API of small, independent functions instead of a few large methods, allowing bundlers to tree-shake unused code. This can reduce bundle size by up to 95% compared to Zod while offering similar ergonomics. Born from a bachelor thesis at Stuttgart Media University, the library is MIT licensed with 100% test coverage and has been adopted by teams needing lightweight runtime validation.

Key capabilities:

  • Tree-shakeable modular design with base bundle under 700 bytes
  • Full type safety and static type inference for validated output
  • Schema support from primitives to complex nested objects
  • parse, safeParse, and type guard (is) APIs for different error-handling styles
  • No dependencies, runs in Node.js, browsers, Deno, and Bun
  • Rich built-in actions for validation and transformation

Typical applications include validating API request payloads, user form input, configuration files, and environment variables. Developers integrate Valibot where data crosses trust boundaries, such as webhooks, file imports, or third-party integrations, to ensure runtime type safety with minimal impact on application size.

GitHub Repositories
110
-4.3%
Trending down this week
Removed in 5 repos