Add representative JSON
Paste an object or array, or upload a valid .json file up to 10 MB.
Generate clean Kotlin data classes from representative JSON with nested models, list inference, nullable properties, serialization annotations, sensible defaults, and Android-ready output.
Create typed Kotlin models from sample JSON in three simple steps.
Paste an object or array, or upload a valid .json file up to 10 MB.
Set the root name, annotations, property naming, nullable behavior, and default values.
Review the inferred classes, copy them, or download a ready-to-edit .kt file.
The generator examines every sampled object in an array, merges available keys, detects missing values, and infers Kotlin primitives, nested data classes, lists, and unions that safely fall back to Any.
JSON keys can become idiomatic camelCase properties while Kotlin serialization annotations retain their original names. Reserved words are wrapped in backticks, empty arrays become List<Any>, and explicit nulls can produce nullable types.
Useful for API responses, Android apps, Ktor services, SDKs, fixtures, and typed data contracts.
Your JSON stays in the browser and is never submitted to the website server.
Every sampled object contributes keys and types instead of relying only on the first item.
Consistent formatting and explicit nullability make generated contracts easier to verify.
Key details about inferred Kotlin data classes.
You can generate kotlinx.serialization @SerialName, Gson @SerializedName, Moshi @Json, or plain Kotlin models.
All sampled objects contribute fields and types to a named item data class used inside a Kotlin List.
Explicit nulls and fields missing from some records can become nullable types, with optional = null defaults.
Keys are converted to camelCase when enabled. Reserved words and unusual identifiers use safe backtick notation.
The syntax is ready to edit, but generated types reflect only the supplied sample. Compare them with the complete API schema before production use.
No. Parsing, inference, copying, and download creation happen locally in your browser.