zod
npmv4.5.4TypeScriptTypeScript-first schema declaration and validation library with static type inference
Safe to adopt
Yes — zod scores well across adoption, maintenance, weight, supply chain, and licensing. 246.7M downloads per week and 13 known dependents. Last published 11 days ago. 50 releases in the last 2 years.
- AAdoption: grade A, Excellent.
246.7M downloads per week and 13 known dependents.
- AMaintenance: grade A, Excellent.
Last published 11 days ago. 50 releases in the last 2 years.
- AWeight: grade A, Excellent.
Zero runtime dependencies, about 5.5 MB installed.
- BSupply chain: grade B, Good.
This package has a single maintainer (bus factor of 1).
- ALicense: grade A, Excellent.
MIT — permissive, with no copyleft found in the dependency tree.
Grades are computed deterministically from registry metadata collected by PackageGraph — downloads, dependents, publish dates, the resolved dependency tree, maintainer count, and declared licenses. No third-party scores are used.
Install cost
What you actually take on by adding zod to a project.
Runtime packages this one declares itself.
Distinct packages in the full runtime tree, deduplicated the way a package manager would.
Unpacked size of this package plus its entire runtime tree.
Longest resolved dependency chain below this package.
Compatibility
- Node.js
- No constraint declared
- Module format
- ESM + CommonJS
- TypeScript
- Types included
- Install scripts
- None
Quick start
A usage example from the zod README.
import * as z from "zod";
const User = z.object({
name: z.string(),
});
// some untrusted data...
const input = {
/* stuff */
};
// the parsed result is validated and type safe!
const data = User.parse(input);
zod vs the alternatives
Packages solving a similar problem in the npm ecosystem, compared on the signals that drive an adoption decision.
| Package | Weekly downloads | Dependents | License | Last release |
|---|---|---|---|---|
| zodthis page | 246.7M | 13 | MIT | 11 days ago |
| @standard-schema/spec | 99.1M | 9 | MIT | 1 day ago |
| valibot | 16.8M | 5 | MIT | 1 day ago |
| @eslint/object-schema | 0 | 1 | Apache-2.0 | 1 day ago |
| joi | 0 | 3 | BSD-3-Clause | 1 day ago |
| json-schema-typed | 0 | 1 | BSD-2-Clause | 1 day ago |
Used by
Popular packages that depend on zod.
Minimal H(TTP) framework built for high performance and portability.
Drizzle ORM package for SQL databases
Runtime typescript and ESM support for Node.js
An implementation of the WebDriver BiDi protocol for Chromium implemented as a JavaScript layer translating between BiDi and CDP, running inside a Chrome tab.
Model Context Protocol implementation for TypeScript
The Expo CLI
Converts Zod schemas to Json Schemas
Web framework built on Web Standards
Protocol layer for describing devframe views as JSON that any renderer can display.
Model Context Protocol implementation for TypeScript - Server package
Model Context Protocol implementation for TypeScript - Client package
Model Context Protocol for TypeScript — public Zod schemas (spec + OAuth/OpenID)
Babel plugin for React Compiler.
Relationship graph
Dependencies (left) and dependents (right) of zod.
Frequently installed together
TypeScript definitions for node
Framework for building one portable devtool integration that runs in any viewer.
Hub layer that orchestrates devframe docks, terminals, messages, and commands on any host.
Expo Router is a file-based router for React Native and web applications.
The Expo SDK
TypeScript definitions for ws
Next generation testing framework powered by Vite
High performance middleware framework
An AST-based pattern checker for JavaScript.
Prettier is an opinionated code formatter
V8 coverage provider for Vitest
An extremely fast JavaScript and CSS bundler and minifier.
Release history
50 releases in the last two years, typically about 0 days apart.
| Version | Published | Size | License |
|---|---|---|---|
| 4.5.4latest | 11 days ago | 5.5 MB | MIT |
| 4.5.3 | 11 days ago | 5.5 MB | MIT |
| 4.5.2 | 12 days ago | 5.5 MB | MIT |
| 4.5.0-canary.20260825T051321 | 12 days ago | 5.4 MB | MIT |
| 4.5.0-canary.20260828T163622 | 12 days ago | 5.5 MB | MIT |
| 4.5.0 | 12 days ago | 5.5 MB | MIT |
| 4.5.1 | 12 days ago | 5.5 MB | MIT |
| 4.5.0-canary.20260828T171753 | 12 days ago | 5.5 MB | MIT |
| 4.5.0-canary.20260828T163402 | 12 days ago | 5.5 MB | MIT |
| 4.5.0-canary.20260828T161354 | 12 days ago | 5.5 MB | MIT |
| 4.5.0-canary.20260828T160755 | 12 days ago | 5.5 MB | MIT |
| 4.5.0-canary.20260828T062315 | 13 days ago | 5.4 MB | MIT |
| 4.5.0-canary.20260828T053040 | 13 days ago | 5.4 MB | MIT |
| 4.5.0-canary.20260827T054049 | 14 days ago | 5.4 MB | MIT |
| 4.5.0-canary.20260827T005050 | 14 days ago | 5.4 MB | MIT |
Overview
zod is an npm package that typeScript-first schema declaration and validation library with static type inference. It is extremely widely used, with about 246.7M downloads per week and 13 known dependents in the graph. The latest version is 4.5.4, released under the MIT license.
Who should use it
Teams working in the npm ecosystem who need typeScript-first schema declaration and validation library with static type inference and value a battle-tested, widely-adopted solution.
When not to use it
Consider an alternative if you need to or if a more actively-maintained option better fits your npm stack.
Pros
- Large, well-established user base (246.7M weekly downloads).
- Ships TypeScript type definitions.
- Clear open-source license (MIT).
- Zero runtime dependencies — minimal footprint.
Cons
- No significant drawbacks detected from available metadata.
Auto-generated from collected registry metadata. No external claims are inferred.
Maintainers
Funding
Frequently asked questions
Should I use zod?
Yes — zod scores well across adoption, maintenance, weight, supply chain, and licensing. 246.7M downloads per week and 13 known dependents. Last published 11 days ago. 50 releases in the last 2 years.
How do I install zod?
Run `npm install zod` to add zod to your npm project.
What license is zod released under?
zod is distributed under the MIT license.
How popular is zod?
zod has approximately 246,731,317 downloads per week and 13 known dependent packages.
Is zod still maintained?
The most recent release of zod (v4.5.4) was published 11 days ago.
Does zod run install scripts?
No. zod does not define preinstall, install, or postinstall scripts, so installing it does not execute publisher-supplied code.