Combine, Zip & Split Lists Online

Combine lists by stacking, joining rows, interleaving (zip), or cartesian product. Use the Split tab to reverse any of these operations.

Alternate items from each list (zip), optionally in blocks of N

Try an example:
Type or Drag & Drop a file
Type or Drag & Drop a file
Output Options
(classic zip)
Output format
Unequal lists
Paste lists above to see results

Frequently Asked Questions

What is the difference between Stack, Row Join, Interleave, and Cartesian?
Four ways to combine lists - pick based on what you want in the output:
  • Stack - append lists one after another. All of A, then all of B. One long combined list.
  • Row Join - merge items at the same position with a separator. Like CONCATENATE across Excel columns: row 1 of A joined to row 1 of B.
  • Interleave - alternate items from each list: a1, b1, a2, b2… Great for paired datasets.
  • Cartesian - every combination of one item from A with one item from B. 3 items × 4 items = 12 pairs.
Stack (A then B)
apple banana - cat dog
Row Join (sep “ / ”)
apple / cat banana / dog
What does Interleave block size N do?
Block size N controls how many consecutive lines are taken from each list before switching.
  • N=1 (classic zip): a1, b1, a2, b2, a3, b3…
  • N=2: a1, a2, b1, b2, a3, a4, b3, b4…
  • N=3: a1, a2, a3, b1, b2, b3, a4, a5, a6…
Useful when your data is grouped - for example interleaving name+email pairs so each person’s details stay together.
Names (A)
Alice Bob Carol
Emails (B)
alice@x.com bob@x.com carol@x.com
Result at N=1
Alice alice@x.com Bob bob@x.com Carol carol@x.com
What is Cartesian product and when should I use it?
Cartesian product pairs every item in List A with every item in List B.
List A (sizes)
S M L
List B (colours)
Red Blue
Result - 6 pairs (3 × 2)
S Red S Blue M Red M Blue L Red L Blue
Good for:
  • Generating test data (all size × colour combinations)
  • Config matrices (all server × environment pairs)
  • Search term combinations (keyword × modifier × location)
Warning: lists grow fast - 1,000 × 1,000 = 1,000,000 pairs. The tool warns you before generating.
How do I handle lists of different lengths?
Open the Options panel and set Unequal lists:
  • Truncate to shortest - stop when the shortest list ends. Clean output with no gaps or padding.
  • Fill with value - pad shorter lists with a string you choose. Leave it blank for empty lines, or type N/A to make missing entries explicit.
  • Repeat shorter - cycle through the shorter list from the beginning. Useful for applying a repeating label or pattern to a longer list - e.g. alternating “Group A” / “Group B” tags.
What are the output format options for Interleave?
When block size is N=1, three output formats are available:
  • Flat - one item per line in interleaved order. Best for pasting into other tools.
  • Tuples - each pair grouped in parentheses: (apple, cat)
  • JSON - each pair as a JSON array: ["apple", "cat"]
Flat
apple cat banana dog
Tuples
(apple, cat) (banana, dog)
For N>1, only Flat is available - block grouping makes the other formats ambiguous.
How do I reverse / undo a merge?
Use the Split tab at the top of the tool. Three reverse operations are available:
  • Split Columns - undoes a Row Join. Paste the joined text, set the same separator, and each column is extracted as a separate list.
  • Unshuffle - undoes an Interleave. Paste the interleaved output, set the same N and number of lists, and the originals are reconstructed.
  • Unstack - undoes a Stack. Paste the stacked text and split on blank lines (or a custom marker) to separate each sub-list.
Can I use more than 2 lists?
Yes - Stack, Row Join, and Interleave support up to 6 lists.
  • Click Add List to add a panel (up to 6 total).
  • Click the × on any panel to remove it (minimum 2 must remain).
Cartesian is limited to 2 lists. Adding a third makes the output exponential - even 10 items × 10 items × 10 items = 1,000 pairs; 100 items each = 1,000,000. The tool keeps Cartesian at 2 for safety. For set analysis across multiple lists - finding common items or items unique to each list - use Multi-List Compare.
What does the Cartesian size guard do?
When the two lists would produce more than 5,000 pairs, the tool pauses and shows the expected count instead of generating automatically - to prevent your browser from freezing.
  • A warning shows the exact pair count before you commit.
  • Click Generate anyway to confirm and proceed.
  • The output panel shows up to 2,000 rows. Click Download to get the full result as a text file.
Example: 100 items × 60 items = 6,000 pairs → guard fires and shows “6,000 pairs - click Generate to proceed.”

Related reading

Share this tool

Featured on ToolDirs
© 2026 ListDiff

Free online list and text processing tools.