Tool
JSON to Java
Generate Java POJOs or records from JSON, with Jackson or Gson annotations
How to use
- Paste a JSON object (or an array of objects) into the input pane.
- Choose POJO (getters/setters) or record style for the generated classes.
- Pick an annotation library: Jackson, Gson, or none.
- Copy the generated classes into your project; nested objects become separate classes.
About this tool
Hand-writing POJOs for a 20-field API response is 20 minutes of copy-paste typos waiting to happen. This generator does the mechanical part: Pascal-casing class names, camel-casing fields, adding @JsonProperty/@SerializedName where the JSON name differs, and choosing wrapper types for nullable fields. The record mode targets Java 16+ projects that model immutable DTOs.