JSON node
JSON Merge
Merge multiple JSON objects into a single object. When objects share the same key, the value from the later (higher-numbered) input takes priority.
Outputs
| Port | Type |
|---|---|
| Output | json |
Screenshots

Overview
JSON Merge combines two or more JSON objects into one unified object. Add dynamic inputs through the Inspector, connect JSON objects to each, and the node merges all their keys into a single output. Inputs are processed in order from [0] upward, so if multiple objects contain the same key, the last one wins.
Non-object inputs (arrays, strings, numbers) are silently ignored — only JSON objects contribute to the merge.
Key order is preserved using Grafit's OrderedJSON system. Keys appear in the order they are first encountered across all input objects.
Examples
Merge two objects:
Input [0]: {"name": "circle", "radius": 1.0}
Input [1]: {"color": "red", "opacity": 0.8}
Output:
{
"name": "circle",
"radius": 1.0,
"color": "red",
"opacity": 0.8
}Override with last-wins:
Input [0]: {"x": 0, "y": 0, "z": 0}
Input [1]: {"x": 5, "y": 10}
Output:
{
"x": 5,
"y": 10,
"z": 0
}The values of x and y from input [1] override those from input [0]. The key z is untouched.
Non-object inputs ignored:
If input [1] is an array like [1, 2, 3], it is skipped. Only objects contribute to the merge.
Use Cases
- Combining separate data sources into a single configuration object
- Layering default settings with user overrides (defaults first, overrides last)
- Merging partial JSON responses from multiple TCP or OSC sources
- Building composite data structures from independently computed sections
Tips
- Input order matters. Connect your base/default object to [0] and overrides to higher-numbered inputs.
- Only JSON objects are merged. Arrays, strings, and other types are silently skipped.
- Key order reflects first-seen order across all inputs — useful when piping to JSON Stringify for readable output.
- For merging arrays, use JSON Array to concatenate elements instead.
A ready-made example project for this node is built into Grafit Pro: select the node in the library and open or drag the example from its description panel.
Open JSON Merge in the interactive catalog →
JSON Merge is one of 381 nodes in Grafit Pro.
Free download. Every feature for 7 days, no card. Then €99.99 once — or keep playing your projects as a Player.