Type-safe Firestore collections and documents powered by Zod.
This monorepo contains two npm packages:
- zod-firebase-admin — for server-side apps using the Firebase Admin SDK
- zod-firebase — for client-side apps using the Firebase Web SDK
Both packages provide the same ergonomic developer experience: define your data once with Zod, get strongly-typed reads/writes, sub-collections, and collection-group queries.
- packages/zod-firebase-admin — Admin SDK (Node.js). Supports transactions, batch writes, preconditions, and admin metadata fields
- packages/zod-firebase — Web SDK (browser/node). Supports aggregate queries via
aggregateFromServer
See each package README for installation, usage, and API reference.
Requirements: Node.js 22+, pnpm.
Common scripts (run at the repo root):
pnpm i
pnpm -r build
pnpm -r test
pnpm -r type-checkMIT