Swift Codable Generator
Paste representative JSON and generate a local Swift struct draft for nested objects, arrays, scalars, and null values.
Heuristic draft only; review types, keys, nullability, and coding keys.
A QUICK WALKTHROUGH
How to use this tool
- Paste valid JSON with an object or array root.
- Choose a root type name.
- Generate and review the heuristic Swift Codable draft.
Heuristic inference
The generator uses JSON.parse and sample values to infer common Swift types. Nulls, mixed arrays, unusual keys, and representative samples may need manual review.
GOOD TO KNOW
Common questions
Does it validate an arbitrary schema?
No. It parses one JSON sample and generates a heuristic draft.
Does it infer generics?
No. It emits concrete Codable structs and basic arrays.