# Merge Lists

> Combine several lists into one. Concatenate appends them in connection order, and Zip merges the items that share a position. Optionally drop duplicates.

Source: https://nodaro.ai/docs/nodes/automate/merge-lists

The **Merge Lists** node combines several lists into one. **Concatenate** appends the lists one after another, in the order you connected them. **Zip (merge items)** merges the items that share a position into one item. With Zip, you can add one shared object to every item of a longer list. An optional switch removes duplicates after the merge. The node is free.

- Found in: Automate › Lists & Batching
- Output: data
- API type: `merge-lists`

## When to use it
- Join the results of two scrapes into one list.
- Combine prompts from two sources into one batch.
- Add the same settings object, such as brand details, to every item of a product list.

## Quick start
### Add the node

Press Tab on the canvas and choose **Automate › Lists & Batching › Merge Lists**.

### Connect two or more lists

Wire each list into the **Lists** input. With **Concatenate**, the first connection's items come first.

### Choose a mode

Open the settings panel and choose **Concatenate** or **Zip (merge items)**. Enable **Remove duplicates after merge** to drop repeats.

### Run it

The **Merged** output carries the combined list. After a run, the panel previews the first items and shows how many there are.

Workflow: Prompts typed in a List and prompts split from a script become one batch, and Generate Image runs once per prompt.

- List → Merge Lists (lists)
- Split Text → Merge Lists (lists)
- Merge Lists → Generate Image (prompt · Each)

## Inputs and outputs
| Input or output | Accepts or sends | What it does |
| --- | --- | --- |
| **Lists** | Two or more lists | The lists to combine. A node that sends a single value counts as a list with one item. |
| **Merged** | A list | The combined list. |

## Settings
| Setting | What it does |
| --- | --- |
| **Mode** | **Concatenate**, the default, appends the lists in the order of their connections. **Zip (merge items)** merges the items that share a position. In Zip mode, shorter lists start again from their first item, and a single object is merged into every item of the longer list. |
| **Remove duplicates after merge** | **Off** by default. **On** drops repeated items, compared by value, after the merge. |

## How Zip merges items

Zip is made for lists of JSON objects. With a product list and one shared object, every product receives the shared fields.

| Connection | Value |
| --- | --- |
| First list | `[{ "name": "Mug" }, { "name": "Cap" }]` |
| Second connection | `{ "brand": "Nodaro" }` |
| **Merged** output | `[{ "name": "Mug", "brand": "Nodaro" }, { "name": "Cap", "brand": "Nodaro" }]` |

## Credits
Merge Lists is free.

## Tips
- **Connect in the order you want.** Concatenate follows the order of the connections, so connect the list that should come first before the others.
- **Compare by a field.** **Remove duplicates after merge** compares whole items. To treat items with the same `id` as duplicates, follow Merge Lists with [Remove Duplicates](https://nodaro.ai/docs/nodes/automate/remove-duplicates).
- **Gather single results.** To gather single results from several nodes, rather than lists, use [Collect](https://nodaro.ai/docs/nodes/automate/collect).

## Frequently asked questions

### What is the difference between Concatenate and Zip in Merge Lists?

Concatenate appends the lists one after another, in the order you connected them. Zip merges the items that share a position into one item, so two lists of 5 items give 5 merged items.

### What happens in Zip mode when the lists have different lengths?

The shorter lists start again from their first item until the longest list ends. A single object from one connection is merged into every item of the longer list.

### Can Merge Lists remove duplicates?

Yes. Enable Remove duplicates after merge to drop repeated items by value once the lists are merged. It is off by default.

### Does Merge Lists cost credits?

No. Merge Lists is free.
