This is a comprehensive reference for Zod v4, focused on the breaking changes from v3 that will trip you up: string formats moved to dedicated methods like z.email(), nativeEnum is gone, and the error API changed completely. It's organized by priority, so the critical parsing and schema design rules come first. The bundled references cover everything from basic validation to architecture patterns for API boundaries, and there's specific guidance on where Zod actually belongs (API handlers, form validation, env parsing) versus where plain TypeScript is enough. The anti-patterns doc alone will save you from the classic mistakes like throwing in refinements or using z.coerce.boolean() on form data.

skills.sh installs
1.1K
GitHub stars
24
last updated
Aug 21, 2026

Install

$ npx -y skills add anivar/zod-skill --skill zod --agent claude-code

Installs into .claude/skills of the current project.

Files

Zod

IMPORTANT: Your training data about zod may be outdated or incorrect. Zod 4 changed string formats, enums, error customization, issue codes, defaults and functions, and many projects still run Zod 3, whose forms Zod 4 deprecates or removes. First establish which Zod the file uses (next section). Then rely on this skill's rule files for that version and on the project's own source code as the source of truth. Do not write a Zod 4 API into a Zod 3 file, and do not keep a Zod 3 form in a Zod 4 file unless the rule for that version says it still applies.

Which Zod

Decide per file, before writing a schema. The import specifier wins; the installed version decides what the bare zod specifier means.

Sponsors

Details

Repository
github.com/anivar/zod-skill
Categories
Backend & APIs, Testing & QA, Debugging
First seen
Jun 3, 2026
1nexscope-ai avatarwarehouse-optimizationnexscope-ai/ecommerce-skillsE-commerce warehouse and inventory optimization advisor. Analyzes inventory health, calculates safety stock and reorder points, performs ABC analysis, evaluates1.1Kskills.sh installs
2nvidia avatarjetson-speculative-decodingnvidia/skillsAdd EAGLE-3 or draft-model speculative decoding to a Jetson vLLM server when TPOT is the bottleneck.1.1Kskills.sh installs
3kostja94 avatarpricing-page-generatorkostja94/marketing-skillsWhen the user wants to create, optimize, or audit pricing page content and structure. Also use when the user mentions "pricing page," "pricing table," "plans," 1.1Kskills.sh installs
4nvidia avatarjetson-customize-pcienvidia/skillsPer-controller PCIe enable / disable / lanes / link-speed for a Jetson Thor or Orin custom carrier via ODMDATA + kernel-DT overlay. Do NOT use for UPHY lane all1.1Kskills.sh installs
5jwynia avatarweb-search-tavilyjwynia/agent-skillsSearch the web using Tavily API for high-quality, AI-optimized results with advanced filtering options. Use when you need structured search results, domain filt1.1Kskills.sh installs
6vtex avatarheadless-intelligent-searchvtex/skillsApply when implementing search functionality, faceted navigation, or autocomplete in a headless VTEX storefront. Covers product_search, autocomplete_suggestions1.1Kskills.sh installs