How to compare two lists
- Paste the first list into List A and the second into List B. Each item goes on its own line, or choose comma, tab, or semicolon as the separator.
- Choose your options. Ignore case treats Apple and apple as the same item. Trim spaces removes stray spaces copied from spreadsheets. Blank lines never count, even if trim is off.
- Click Compare, then pick which result to view: items in both lists, only in A, only in B, every unique item, or the duplicates inside each list.
- Copy the result, download it as text, or download a CSV with four columns side by side for Excel or Google Sheets.
What each result means
| Result | Set operation | Example use |
|---|---|---|
| In both | Intersection of A and B | Customers who are also newsletter subscribers |
| Only in A | Difference A minus B | Emails not yet invited |
| Only in B | Difference B minus A | New keywords a competitor ranks for |
| Union | A and B together, without repeats | Merging two contact lists |
| Duplicates | Values repeated inside one list, shown once | Cleaning a list before import |
Example
List A: apple, banana, Cherry, date, banana. List B: cherry, date, elderberry, fig. With ignore case and trim on, the lists share Cherry and date. Only A has apple and banana, only B has elderberry and fig, and banana is a duplicate within A. The union has six unique items.
Comparing lists in Excel vs. online
In Excel you can use =COUNTIF(B:B,A2)>0 or XLOOKUP to flag matches, but that means writing formulas, dealing with extra spaces, and repeating the check in each direction. This tool returns all of those results together and handles case and end spaces. A normal laptop can compare tens of thousands of lines, including about 50,000, because the check uses hash maps rather than nested loops. The Excel and Google Sheets guide shows the formula versions.
Your lists stay on this device
The comparison runs in JavaScript in your browser. Nothing is uploaded, so it is a practical way to handle customer emails, order numbers, and other private lists. Still check the output before a mail merge or import.
Popular uses
- Marketing: find which leads from an event are already in your CRM, or remove unsubscribed emails from a mailing list.
- SEO: compare your keywords with a competitor's to spot content gaps.
- Inventory: check which SKUs are in the warehouse export but missing from the online store.
- Teachers and HR: see who has not submitted a form by comparing the roster with the responses.
- Developers: diff two sets of IDs, packages, or file names without writing a script.
If your data has a header row, remove it first, or it will be compared like any other item.
Handling messy data
Lists copied from spreadsheets, PDFs, or email often contain trailing spaces, blank lines, mixed capitalization, and Windows line endings. With trim and ignore case on, those differences are normalized before comparing, so "[email protected] " and "[email protected]" count as the same item. The original spelling of the first occurrence is kept. Spaces inside a line are not collapsed, and lookalike characters are not treated as matches. This is an exact comparison, not a fuzzy one.
Frequently asked questions
How do I find the differences between two lists?
Paste both lists, click Compare, and choose Only in A or Only in B to see the items that appear in one list but not the other.
Is the comparison case-sensitive?
Not by default. Untick Ignore case to treat Apple and apple as different items.
Does this page also show repeats inside one list?
Yes. After you compare two lists, duplicates within A and within B are listed once each, using the first spelling. To strip repeats from a single list and keep the first line, use the remove duplicates page. To list only shared items, use the find duplicates in two lists page.
How many items can I compare?
Tens of thousands of lines work in the browser, including lists around 50,000 lines. The limit is your device memory.
Can I compare comma-separated values?
Yes. Set Split items by to comma, tab, semicolon, or any of these.