Using the merge node - merge by key
Needs changesWhat this workflow does
This workflow has 5 nodes and runs from “Data” (no trigger node, so run it manually or call it from another workflow). It uses only n8n's built-in nodes.
How it runs
Trigger: From “Data” (no trigger node, so run it manually or call it from another workflow).
- Data (Function): runs custom JavaScript (legacy Function node)
- Data (Function): runs custom JavaScript (legacy Function node)
- Convert Data (Function): runs custom JavaScript (legacy Function node)
- Convert Data (Function): runs custom JavaScript (legacy Function node)
- Merge: merges the data from its input branches
Before you upgrade to n8n 3.0
1 thing in this workflow is removed in n8n 3.0. Fix it before you upgrade:
- Function (legacy) in Data 1, Data 2, Convert Data 1…: replace with Code node, mode 'Run Once for All Items'.
Rather not rewrite it? Many of these flows can be rebuilt in Make (free plan).
Published 2019 — 25% of templates published before 2025 need changes for 3.0. See how template age affects 3.0 readiness →
| Removed in 3.0 | Replace with |
|---|---|
| Function (legacy) Data 1, Data 2, Convert Data 1, Convert Data 2 | Code node, mode 'Run Once for All Items' |
Nodes used (2)
- Function
n8n-nodes-base.function - Merge
n8n-nodes-base.merge
From the author
This is an example of how you can make Merge by Key work. The “Data 1” and “Data 2” nodes simply provide mock data. You can replace them with your own data sources. Then the “Convert Data” nodes are important. They make sure that the different array items are…