Compare Two Lists
Paste two lists below to compare them: every item lands in one of four counted groups, and nothing you paste leaves this tab.
What happens to my lists?
Trim spaces stops stray spaces pasted from a spreadsheet from hiding a match. Ignore case treats Apple and apple as one item.
Read the privacy policyFour Answers at Once
The guest-list sample below is a live run of this comparator: every count and every item comes from the same code the workbench uses when you compare two lists.
Margeaux Chen Jonah Feld Ines Okafor Ruth Vance Devon Marsh
Invited, no reply yet: chase this list first.
Tobias Wren Alma Reyes Priya Natarajan
Matched pairs: the invitation reached them.
Caleb Lund Sofia Petrov
Replied but never invited: a typo or an extra plus-one.
Margeaux Chen Tobias Wren Alma Reyes Priya Natarajan Jonah Feld Ines Okafor Ruth Vance Devon Marsh Caleb Lund Sofia Petrov
Every name from either side, ready to paste anywhere.
Counts first: each group badge is the live count, so you know the size of an answer before you read it.
What It Means to Compare Two Lists
To compare two lists is to sort their items into four groups: the items only the first list holds, the items only the second holds, the items both hold, and everything from either side. Set terms name the same four answers: two differences, an intersection and a union. Each line is one item, so a column copied from a spreadsheet compares as it is.
The comparator treats each list as a set: an item that repeats inside one list still counts once, in the order it first appeared. The counters under each box show lines, unique items and repeats, so the collapse is visible before you read the results instead of a surprise after.
Where a list comparison earns its keep
- Guest lists: paste the invite list and the replies to see who to chase.
- Follower audits: who you follow vs who follows you back, no screenshots.
- Spreadsheet columns: skip the COUNTIF for a one-off check between two exports.
- Orders vs deliveries: find what the warehouse never shipped.

How to Compare Two Lists in Excel
Excel answers three different jobs: a quick visual pass, a per-row verdict, or a lookup you can extend. Pick the method by what you need to do next, or skip the formulas and compare two lists online in this tool when the answer is one-off.
| Method | What it answers | Watch out |
|---|---|---|
| Conditional formatting | Highlight Cells Rules > Duplicate Values marks items that appear in both columns when you select both ranges. | Visual only: no countable output, and it repaints silently when the data moves. |
| COUNTIF helper column | =IF(COUNTIF($B$2:$B$500,A2)=0,"Missing in B","In both") gives every A row a verdict you can filter. | One verdict per column pair; the $B$2:$B$500 range needs maintaining by hand. |
| XLOOKUP | =XLOOKUP(A2,B:B,B:B,"Not found") returns the matching B value or a fallback. | Microsoft 365 or Excel 2021 only; older workbooks need VLOOKUP wrapped in IFNA. |
Formulas or a paste?
Formulas recalculate when either column changes, which is their job. For a one-off answer, paste each column into a box above and compare two lists with all four counts at once: the comparator is free, needs no helper column, and never touches the source sheet.
How to Compare Two Lists in Python
Two lines of set algebra answer the set question: set(a) - set(b) for items only a holds, set(a) & set(b) for the shared ones. How to compare two lists in Python depends on which recipe below matches your job, because sets drop duplicates and order on the floor.
only_in_a = set(a) - set(b) only_in_b = set(b) - set(a) shared = set(a) & set(b)
b_keys = set(b) only_in_a = [x for x in a if x not in b_keys] # order and duplicates survive
from collections import Counter missing = Counter(a) - Counter(b) extra = Counter(b) - Counter(a)
List Comparison Questions
How do I compare two lists to find matches?
Paste the first list into List A and the second into List B, then press Compare lists. The In both tab lists every matched item once, with the count on its tab; Only in A and Only in B hold the differences.
Can I compare two columns from Excel?
Copy each column and paste it into its own box: every cell becomes one line, and Trim spaces removes stray spaces copied with the cells. For recurring checks, compare two lists in Excel with the formula methods above instead.
What happens to duplicate items?
Each list is compared as a set: a repeated item appears once per group, in the order it first appeared. The counters under each box show lines, unique items and repeats, so you can see the collapse before reading the results.
Is the comparison case sensitive?
Yes by default: Apple and apple are different items. Turn Ignore case on to match them; the result keeps the spelling list A uses, so your original capitals survive.
Why do two items that look identical show as different?
Something invisible rides inside one of them: a non-breaking space, a zero-width mark, a direction control. Matching stays exact on purpose, so run the stubborn list through the invisible character remover and compare again.
Are my lists uploaded anywhere?
No. The comparison runs in this browser tab: nothing you paste is sent, stored or logged, and closing the tab clears both lists.
Cleaning a single list first? Remove duplicate lines, then compare two lists side by side.Pasting from a spreadsheet? The Excel paste guide covers what a column copy carries.Back to the format remover