List compare

Compare two lists and find common or unique items.

The interactive form is ready when JavaScript is enabled.

How to use

Paste two lists to see what they share, what only the first one has and what only the second one has — the three answers you need when reconciling an export against a system, or last month's list against this month's.

This is set arithmetic, so repeats inside a list collapse before the comparison: it answers which values appear, never how many times. If a value appearing twice matters — a double charge, a duplicated row — that is a different question, and deduplicating first will hide it. The normalisation traps are the same as anywhere else: a trailing space or a different kind of apostrophe puts an item in 'only in A' while you can plainly see it in B.

Example

Two items occur in both lists; each list also has one item absent from the other.

  • Two email listsWho is on both, who is only on one.
  • Yesterday's export against today'sOnly in B is what was added; only in A is what left.
  • A list with stray spacesTrim first, or matching items are reported as different.

Frequently asked questions

Does it count how many times a value appears?

No. Each list is reduced to its distinct values first, so three copies of the same line count once. For anything where the count is the point — reconciling quantities, finding a duplicate payment — compare the counts separately; a set comparison will quietly tell you everything matches.

An item is in both lists but shows as only in A — why?

The two copies are not identical as text. Enable trimming and case-insensitivity, which covers most of it. What remains is usually a character that looks the same and is not: a non-breaking space, a typographic apostrophe, or an accented letter stored in two different ways.

Related tools