JSON to Java
About this tool
Hand-writing Java classes from a payload misses fields. Paste JSON to generate classes. Enable Lombok, Jackson, or Gson as needed. Use the online cURL generator for HTTP commands.
Features
- Builds Java fields from a sample
- Optional Lombok to skip getters
- Jackson or Gson annotations on demand
How to use
- Paste a JSON sample and set the class name.
- Optionally enable Lombok, Jackson annotations, or Gson.
- Copy the Java class into your project.
When to use it
- Create an entity from an API JSON
- The project already uses Lombok
- Serialization is Jackson or Gson
Examples
- {"createdAt":"2026-01-01"} maps to a field inferred from the sample.
- Lombok mode emits @Data-style annotations instead of paired getters.
FAQ
Is the JSON uploaded?
No. Generation stays in the browser.
How is this different from the online cURL generator?
This page builds a Java Class from JSON. The online cURL generator turns an HTTP request into a curl command.
Back to JSON Tools Hub
Guides