JSON Merge

Deep-merge two or more JSON documents into one — objects merged recursively, later values win, arrays replaced or concatenated. Runs in your browser; nothing is uploaded.

Merged JSON

About this tool

JSON Merge deep-merges two or more JSON documents into one. Paste your JSON values one after another (separated by whitespace or a newline) — they're merged left to right.

The merge rules:

Set Indent for the output (or 0 to minify). Everything runs locally in your browser via WebAssembly — your data is never uploaded.

Handy for

FAQ

Can I delete a key by setting it to null in a later document?

No — this is a deep merge, not JSON Merge Patch (RFC 7386). A null in a later document is treated as an ordinary value, so the key stays in the output with the value null rather than being removed.

How do I separate the documents I paste in?

Just put whitespace or a newline between them — the input is read as a stream of JSON values, merged left to right. Two, three, or more documents all work; pasting a single document simply reformats it at your chosen indent.

Are arrays merged element by element?

No. When two arrays collide, the later one replaces the earlier by default, or is appended to it if you tick Concatenate arrays. There is no index-wise merging of array elements — only objects merge recursively.

Can I get minified output?

Yes — set Indent to 0 to emit the merged document on a single line. Values 1–8 pretty-print with that many spaces per level (the default is 2).

Developer & Automation Access

Run it from the terminal

Same engine as this page, headless — via the gizza CLI:

gizza tool json-merge '{"a": 1, "nested": {"x": 1}}
{"b": 2, "nested": {"y": 2}}'

New to the CLI? Get gizza →

Open it by URL

Pre-fill and auto-run this tool with query parameters — the names match the API/CLI:

https://gizza.ai/tools/json-merge/?documents=%7B%22a%22%3A%201%2C%20%22nested%22%3A%20%7B%22x%22%3A%201%7D%7D%0A%7B%22b%22%3A%202%2C%20%22nested%22%3A%20%7B%22y%22%3A%202%7D%7D&concat_arrays=true&indent=2

Machine-readable descriptor: tool.json — title + parameters JSON Schema for agents.