Valibot
Modular, type-safe schema validation library with bundle sizes starting under 1KB
Repository Health
Technical Analysis
Valibot is a TypeScript schema validation library built around many small, independently importable functions rather than a handful of large chainable methods. Schemas are composed by piping together primitive validators and transformation actions (v.pipe(v.string(), v.email())), which lets bundlers tree-shake away everything not actually used — Valibot advertises bundle sizes starting under 1KB versus tens of kilobytes for comparable libraries like Zod.
Beyond runtime validation and parsing (parse, safeParse, is), the project is a monorepo that also ships companion packages for JSON Schema conversion (@valibot/to-json-schema) and internationalized error messages, plus a codemod for migrating existing Zod schemas. Full static type inference means a validated schema’s TypeScript type is derived automatically via InferOutput.
What You Get
- Composable schema builders (
v.object,v.string,v.array,v.union, etc.) combined viav.pipe()with validation/transformation actions parse()(throws on failure),safeParse()(returns a result object), andis()(type guard) APIs for validating unknown data- Full static type inference via
v.InferInput/v.InferOutput, so a schema’s TypeScript type never has to be hand-written - Companion
@valibot/to-json-schemapackage for converting Valibot schemas to standard JSON Schema - An official Zod-to-Valibot codemod for migrating existing schema definitions
- Internationalized error message packages for validation failures in multiple languages
Common Use Cases
- Validating incoming API request bodies or query parameters on a server with automatic TypeScript types
- Validating and parsing form input on the client with detailed, per-field error messages
- Validating environment variables and configuration files at startup
- Converting existing schemas to JSON Schema for OpenAPI docs or LLM tool-call argument validation
- Migrating an existing Zod-based codebase to a smaller-bundle alternative via the provided codemod
Under The Hood
Architecture: The monorepo’s library/ package holds the actual valibot npm package; library/src/schemas/ defines type-specific schema constructors (string, number, object, array, union, and dozens more), library/src/actions/ defines composable validation/transformation actions (email, minLength, trim, brand, etc.), and library/src/methods/ implements the parse/safeParse/is entry points that run a schema’s pipeline against input data. packages/to-json-schema and packages/i18n are separate, independently versioned workspace packages consuming the core library’s schema objects.
Tech Stack: Pure TypeScript with zero runtime dependencies, managed as a pnpm workspace (pnpm-workspace.yaml) with per-package package.json/build config, and Vitest for testing (library/src/vitest).
Code Quality: The library/src tree contains 272+ .test.ts files, essentially one per schema type and action, giving near-total coverage of the composable primitives — consistent with the README’s claim of 100% test coverage. Naming is highly consistent (each action/schema is one small file matching its exported name), and the codebase carries zero runtime dependencies, minimizing supply-chain and version-conflict risk for consumers.
API Design: The core design decision — many small single-purpose functions composed via pipe() instead of a large chainable builder object — is explicitly built to let bundlers eliminate unused code, and it keeps the public API surface predictable: every validator/action is a plain function with the same shape, so learning one teaches you the pattern for all of them.
Used by 12 apps in this directory
Cap
Team Chat · Video Conferencing
Open source Loom alternative with GPU-accelerated recording, instant share links, AI summaries, and full self-hosting via Docker Compose.
Convex Backend
Developer Tools · Databases
Open-source reactive database that lets developers build live-updating apps with pure TypeScript, strong consistency, and real-time subscriptions—no separate API layer required.
flue
AI Agents · Developer Tools
Build autonomous AI agents and powerful workflows with a programmable TypeScript harness that gives any model sessions, tools, sandboxes, and durable execution.
Kaneo
Product Management · Productivity · Project Management
Lightweight self-hosted project management that gives you kanban boards, GitHub sync, and full team collaboration without the enterprise bloat.
LogChimp
Marketing · Product Management
Collect customer feedback, prioritize features with upvotes, and build transparent product roadmaps — fully self-hosted and open source.
Mastra Code
AI Code Assistants
"A coding agent that never compacts" — a terminal-based AI coding agent built on the Mastra framework, with Observational Memory instead of context compaction, multi-model support, and OAuth login for Claude Max or ChatGPT Plus.
mesh-llm
AI Development · AI Agents
Mesh LLM pools GPUs and memory across every machine you own into one OpenAI-compatible API, so agents tap distributed compute instead of a single GPU box or a metered cloud bill.
Novu
Developer Tools
Open-source communication infrastructure that connects your products and AI agents to every channel your users live on — Inbox, Email, SMS, Push, Chat, and more.
open-pencil
AI Design Tools · Design Tools
An open-source design editor that reads native Figma files, ships a built-in AI assistant with 100+ design tools, and offers real-time serverless collaboration — all without giving up your files.