Zod is a TypeScript-first schema validation library with runtime inference, providing safe parsing for forms, APIs, and configs without codegen.
Chainable API for complex schemas.
Use Zod when:
Infer types from schemas.
.safeParse for errors.
Transformers.
Small, fast.
No deps.
Note: z.object({}).parse(data).
Refine for custom.
SuperRefine for complex.