List Matcher

Lists are processed in this browser tab and aren’t uploaded.

English

List diff: see what was added and removed

Paste the old version of a list on the left and the new version on the right. Every item is marked + added, − removed or unchanged, and you can copy the whole diff or a single group.

Try a sample workflow

Try an example or add your own two lists below.
More examples (9)

People and education

Operations and finance

Data and accounts

Which part do you need?

Add two lists to see how they compare.

Choose which parts to include (you can pick several)

Result

Matching rules

Blank lines are skipped. An item listed twice in the same list counts once. Rules change how items are matched, never your lists.

Match details

No result yet.

Diff two lists in three steps

  1. Paste the old list on the left and the new list on the right, one item per line, or open a TXT, CSV or Excel file.
  2. Read the Diff view: removed items (−) first, then added items (+), then the unchanged ones.
  3. Copy the diff, or copy only Added or only Removed with the button beside each group.

Common questions

What is a list diff?

A list diff shows how two versions of a list differ: which items were removed, which were added and which stayed. Each item is compared as a whole value, so you get three groups instead of a line-by-line text comparison.

Does the order of the items matter?

No. A list diff compares membership, not position. If the new list holds the same items in a different order, the diff shows no changes. When positions matter, as in a document or source code, use a text diff instead.

What do the + and − signs mean when I copy?

Copy and TXT download follow the unified format of diff -u: - before a removed item, + before an added item and a space before an unchanged one. CSV download adds a change column with removed, added or unchanged.

Why does an item show up as both removed and added?

The two versions differ in something that is hard to see: upper and lower case, spaces at the start or end, or hidden characters such as non-breaking spaces. Turn on the matching rules and the pair moves to Unchanged.

How are duplicate lines counted?

An item repeated within one list counts once, so a second copy of an existing item is not reported as added. Blank lines are skipped.

Can I diff two Excel or CSV exports?

Yes. Open both files, pick the column that identifies each row, such as an ID or email, and choose Whole rows to copy complete rows with a Change column.

What a list diff shows

A list diff compares the old version of a list with the new one and puts every item into one of three groups:

  • Removed (−): in the old list, missing from the new list.
  • Added (+): in the new list, not in the old list.
  • Unchanged: in both versions.

In set terms, removed = old − new, added = new − old and unchanged = old ∩ new. Items are matched as whole values, so a list diff answers “what changed?” for SKUs, customer IDs, email addresses, package names or any list with one value per line.

Example

Old list: SKU-1001 to SKU-1006. New list: SKU-1002, SKU-1003, SKU-1005, SKU-1006, SKU-1007, SKU-1008 and SKU-1009. The diff:

-SKU-1001
-SKU-1004
+SKU-1007
+SKU-1008
+SKU-1009
 SKU-1002
 SKU-1003
 SKU-1005
 SKU-1006

Two removed, three added, four unchanged. It is the Catalog example above the tool, so one click shows the same result.

List diff or text diff?

A text diff, such as the diff command or an online text compare, lines two documents up by position. Move one line and it reports a deletion and an insertion; sort the file and almost every line changes. A list diff ignores position and only asks whether each item is present. Use a text diff for prose, code and configuration files, where order carries meaning. Use a list diff for inventories, member lists, exports and dependency lists.

The same groups on the command line

The POSIX comm utility prints the same three groups for two sorted files: lines only in the first file, lines only in the second and lines in both (POSIX comm specification).

sort -u old.txt > old.sorted
sort -u new.txt > new.sorted
comm -23 old.sorted new.sorted   # removed
comm -13 old.sorted new.sorted   # added
comm -12 old.sorted new.sorted   # unchanged

comm needs sorted input and compares exact bytes. This page needs no sorting and can ignore case or stray spaces when you ask it to. Before publishing, we ran this page’s comparison and comm on 320 randomly generated list pairs; every removed, added and unchanged group matched.

Matching rules that change a diff

By default two items match only when they are identical, including upper and lower case. Open Matching rules to ignore case (useful for emails), ignore spaces at the start and end, remove hidden characters, ignore extra spaces inside items or ignore leading zeros in numbers. Rules change how items are matched, never your lists, and the diff updates as soon as you switch one. Both lists are processed in this browser tab and aren’t uploaded.