Skip to content

JSON Transformer

Rename JSON keys, move fields, flatten nested objects or set defaults with visual rules. Use the same sequence of rules on another file by saving it as a recipe.

Use the JSON Formatter if you only need to make the same data easier to read.

Use it when
An app expects firstName but your data uses first_name. Rename the field and save the rule for the next file.
Keep in mind
You choose the fields and rules. The Transformer can’t infer what another app expects.
Before
{ "first_name": "Alex" }
After
{ "firstName": "Alex" }
Input limit: 5 MiB

Transformation rules

Add a rule to change the input.

Your input stays in this browser. We don’t upload it. How we handle your data .

How to transform JSON

Paste JSON or open a local file. Add rules in the order you want them to run, then select Run transformation. Review the output and copy it or download a JSON file.

Frequently asked questions

How do I rename a key in JSON?

Add a Rename field rule. Enter the current path, such as /first_name, and the new path, such as /firstName. Select Run transformation and check the renamed field in the output.

Can I rename a field in every object in an array?

Yes. Choose Each item in array and select the array, such as /users. Use paths relative to each item, such as /email and /contactEmail. Leave the array path empty if your input is an array at the top level.

How do I flatten a nested object in JSON?

Add a Flatten object rule and select a path such as /address. The fields inside that object, such as city and postcode, move to its parent. You can apply the same rule to objects inside a list with Each item in array.

What happens if the destination field already exists?

The transformation reports a conflict when a rule would write over an existing value. Enable Replace existing values on that rule if you want to allow it, then review the affected fields before applying the result.

Can I reuse a transformation on another file?

Yes. Open Recipe and select Download recipe. Later, use Import recipe to restore the same rules in the same order. The recipe includes any default values you entered, so check those before sharing it.

Related tools