Compare Two Lists

Live

Compare Two Lists compares two lists and shows the items only in the first, only in the second, in both, and in either.

Runs in your browser: what you enter is processed on your device and not uploaded to MyToolDock.

What is Compare Two Lists?

Compare Two Lists compares two lists and shows the items only in the first, only in the second, in both, and in either. Items are compared as whole lines. Up to 500,000 lines per list.

How It Works

  1. Enter two lists with one item per line, plus options to ignore case, trim spaces and skip empty lines in the input fields on this page.
  2. Press the button to run Compare Two Lists.
  3. Read four lists with counts: only in A, only in B, in both and in either list in the result area, and copy or download it.

Common Uses

Good to Know

Each item is counted once, so repeats inside a list do not change the results.

How it works

Paste or type one list in each box, one item per line. The page instantly shows four lists: items only in A, items only in B, items in both, and items in either list. Each box has a Copy button.

Ignore case treats Apple and apple as the same item; trim removes spaces around each line; skip empty lines ignores blank rows. You can keep the original order or sort A to Z or Z to A.

Worked example

Random lists of words (with different capitals, extra spaces, blank lines, accents and repeats) were compared with every combination of the three options and the three sort orders, and the four result lists matched what Python sets give, including the order of first appearance. A test with 60,000 lines in each list, 30,000 of them shared, also gave the correct counts.

Limits

Lines are compared as whole lines, so it does not match parts of a line. Repeats inside a list count once, and the spelling shown is the one that appears first. With "Ignore case" on, accents still matter, so e and é are different. Each list can have up to 500,000 lines.

Frequently Asked Questions

Does the order of the lists matter?

Only for the "only in A" and "only in B" lists. "In both" and "in either" are the same whichever way round you paste them, apart from item order.

Can I compare two spreadsheet columns?

Yes. Copy each column from your spreadsheet and paste it into a box.

Are my lists uploaded?

No. The comparison runs in your browser.

What does Compare Two Lists do?

Compare Two Lists compares two lists and shows the items only in the first, only in the second, in both, and in either. Items are compared as whole lines. Up to 500,000 lines per list.

What do I need to enter in Compare Two Lists?

Two lists with one item per line, plus options to ignore case, trim spaces and skip empty lines.

Is my data private in Compare Two Lists?

Nothing is uploaded.

Is MyToolDock Compare Two Lists free to use?

Yes, MyToolDock Compare Two Lists is 100% free with no registration, subscriptions, or limits. All features are fully unlocked.

Related Tools

Column to Comma Separated List Converter Compare PDF Files Anagram Checker ASCII Table Generator Diff Checker Base64 Text Decoder

More Text Tools guides

More in Text Tools · Browse all tools

Developer Scratchpad

Copied to clipboard!