What is a JSON to Kotlin converter?
A JSON to Kotlin converter generates idiomatic data classes from JSON samples: immutable val properties, nullable types with defaults, and nested classes named after their keys. Great for Android and JVM API models.
How to generate data classes
Paste a JSON object, optionally rename the root class, and copy the result. All classes are emitted together so you can paste them into one file.
Types and nullability
String, Int, Double, and Boolean are inferred from the sample; collections become List<T>. Anything optional or null becomes T? = null.
Nesting and naming
Nested objects become their own data classes with names derived from the parent, e.g. address inside Root becomes RootAddress — collisions get numeric suffixes. Keys that differ beyond casing from the property name receive an explicit annotation.