A runtime conversion library that creates Zod schemas from JSON Schema definitions, version 0.5.2. Unlike json-schema-to-zod which generates source code, this executes the conversion at runtime, enabling dynamic schema generation. Supports both Zod 3 and Zod 4 (latest) with ESM and CJS. Maintained by Glide Apps with CI and coverage badges. Key differentiator: runtime conversion vs. code generation, allowing use with dynamic or remote schemas.
npm install zod-from-json-schemaNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Demonstrates runtime conversion of a JSON Schema to a Zod schema and parsing valid data.
Check the documentation for supported keywords; consider flattening references before conversion.
Upgrade to Zod 4 and use the latest zod-from-json-schema version.
Validate your JSON Schema externally using a library like ajv before conversion.
Pin to a specific minor version and test after upgrades.
Use import { convertJsonSchemaToZod } from 'zod-from-json-schema'Simplify the schema to avoid unsupported keywords, or preprocess with another library.
Run npm install zod-from-json-schema and verify import path.