JSON to TypeScript Type Guard Generator
Sample JSON → interface + isXxx guards · zero runtime deps · nesting and arrays covered
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.