Inference rulesEach type gets an interface plus an isXxx guard function; missing fields check undefined and nullable values check null; arrays are validated element by element; mixed types are judged branch by branch as unions. The output has zero runtime dependencies.Runs locally — no fixed size limit (bounded by browser memory)
Sample JSONJSON
Paste or type JSON
Generated schemaType Guard
Paste or type JSON
JSON → zero-dependency type guards · runs locally · no upload

JSON to TypeScript Type Guard Generator

Sample JSON → interface + isXxx guards · zero runtime deps · nesting and arrays covered

🔒Your data is processed locally in the browser — never uploaded, never stored

No upload, no storage

JSON is processed in memory and never sent to a server.

Share via URL fragment

Share links encode data in the # anchor — never sent to a server.

Remember last edit

Optionally keep your last input locally; clear it with one click.

Why generate TS type guards from JSON

Interface + guard together

Each type ships both an interface and an isXxx(v): v is Xxx guard, ready to narrow runtime data the moment you paste it in.

Zero runtime dependencies

Unlike Zod / Valibot, the output is plain TS functions — no runtime library added, zero bundle-size cost.

Optional, nullable, nested

Missing fields check undefined, nullable values check null, nested objects call child guards, arrays validate every element.

Unions, not any

Fields with mixed sample types are judged branch by branch as unions instead of being loosened to any.

Runs locally — no upload

Generation happens entirely in your browser. Nothing is uploaded or stored.