JSON to TypeScript

About this tool

Paste any JSON and get ready-to-use TypeScript interfaces. Types are inferred recursively: nested objects become their own named sub-interfaces (from the field name), arrays get an element type inferred from their items (unioned when items differ), and null values produce nullable types. The root interface name is configurable and defaults to Root.

This is handy for turning an API response into typed models in seconds. The whole tool is plain JavaScript running locally in your browser — no build step, no server, no upload — so it is safe for private or proprietary payloads.

Related tools

JSON FormatterJSON to YAMLJSON to CSV