Compare Two Lists

Paste one item per line to find matches and differences between two lists.

How to use

These are example steps; replace the values for your task.

  1. Paste each list with one item per line.
  2. Review common items and items unique to either list.

Matching options

Each list supports up to 50,000 lines and 2 million characters. Split larger lists into batches. This tool processes your inputs and results in your browser without saving or sending them. Save any results you need before leaving the page.

Check your lists and options, then select Compare lists.

How to compare your lists

Paste a column from Excel or Google Sheets into each box. Choose your matching options, compare, then copy or download the groups you need. You can leave one list empty.

Matching and result order

Repeated items appear once in each result. The first spelling and input order are preserved; shared items use the spelling from A. All Unique lists A's items first, followed by items found only in B.

By default, surrounding whitespace and empty lines are removed, and letter case is ignored. Character width, accents, and punctuation are not normalized. Matching is not language-specific or fuzzy.

If you keep empty lines, a blank line counts as an item. With trimming off, whitespace-only lines are distinct from empty lines. Copy and TXT add a line ending after each item, preserving blank items.

Example

If A contains SKU-001, SKU-002, and SKU-003, and B contains SKU-002, SKU-003, and SKU-004: Only in A is SKU-001, In Both is SKU-002 and SKU-003, and Only in B is SKU-004. Enter each item on its own line.

Try a use case and check the result

Find items only in A, in both lists or only in B from one-item-per-line lists or product codes.

Trying an example replaces the input and settings and runs the tool above. Restore previous input restores the preceding input and settings, not a saved copy of the calculated result; run again as needed. Existing storage rules apply.

After trying multiple examples, repeat Restore previous input to return to your original input. History is kept only in this page; restore any input you need before closing it.

Compare product codes after collapsing duplicates

Input and settings

List A:
SKU-1
SKU-2
SKU-2
List B:
SKU-2
SKU-3

Trim outer spaces, ignore empty rows and match case: on

Expected result

Only A: SKU-1
Both: SKU-2
Only B: SKU-3
All: SKU-1, SKU-2, SKU-3

Match case-insensitively and retain A’s spelling

Input and settings

List A: Apple
List B: apple

Trim outer spaces and ignore empty rows: on. Match case: off

Expected result

Both: Apple
Only A and only B: 0 items

How to read the result

Repeated rows count once; this does not compare quantities. Shared items and the union retain A’s spelling and order, followed by B-only items. Result text fields and TXT exports include a final newline.

Scope and limits

This does not select CSV columns or use fuzzy matching. Ignoring case does not normalize width, accents or Unicode forms. Each list is limited to 50,000 rows and 2,000,000 UTF-16 code units. Editing lists or options invalidates results and requires comparison again.

Verification: existing compare and serialize functions check group membership, deduplication, original spelling and order, and the final newline against all four result fields.

Continue with the next task

Compare repeated items as sets

Example input

A: apple
apple
pear / B: pear
melon

Result

Only A: apple / Both: pear / Only B: melon

Each matching key is deduplicated within its list, keeping the first spelling. This compares membership rather than occurrence counts.

Each side is limited to a string length of two million and 50,000 rows. Comparing repetition counts requires a separate frequency analysis.

Frequently asked questions

How is this different from a text diff?

List comparison finds matching items even when their line positions differ. Use Text Difference Checker to review edits or line changes between versions of a document.

What lists can I compare?

Compare product codes, names, keywords, or any one-item-per-line list. Email addresses and URLs are compared as text, not opened or contacted. Multi-column CSV is not parsed into separate fields.

Does sharing include my lists?

Sharing sends only the tool title and page URL, never your inputs or results. Usage analytics also exclude list content.

Related tools

Inputs and storage

Keep any content you need before clearing. This tool does not autosave inputs or results. Reloading or closing the page, clearing inputs or resetting may discard your work.

Favorites and language preferences are stored separately and may be lost when site data is cleared. Tool resets and site-data deletion do not delete files already downloaded to your device.

Explore tools & games

All 120 tools · 16 games

All 120 tools · 16 games

Text & writing 26

Calculators & converters 22

Date & time 12

Images & PDF 26

Data & web 28

Random & handy 6

Games 16