List Compare — Intersection, Union & Difference
Compare two lists line by line: find common items, items unique to each, union or symmetric difference — in your browser.
A: 4 · B: 4 · Result: 2
How to use
- Paste one list into A and the other into B, one item per line.
- Choose a comparison mode (in both, only A, only B, union, only one).
- Toggle case sensitivity or trimming, then copy the result.
About this tool
ShowHide
Paste two lists and see how they relate: the items in both, the ones only in the first, the ones only in the second, the union, or the entries that appear in exactly one of them. Comparison is per line, with optional trimming so a stray space at the end of a copied cell does not make two identical values look different, and optional case sensitivity for when it genuinely matters. Duplicates inside a single list collapse, and the first spelling you used is the one shown, so a list pasted from a spreadsheet keeps its original capitalisation in the output even when matching ignores case. Good for reconciling two exports, checking which users are missing from a group, or diffing a package list. Everything runs locally.
Frequently asked questions
Are duplicate lines counted?
No. Each list is de-duplicated first, so an item that appears multiple times in a list is treated as one. The item counts shown reflect the unique items in each list.
What does 'only in one list' mean?
It is the symmetric difference: every item that is in exactly one of the two lists (the items only in A plus the items only in B), excluding anything they share.
How does case sensitivity work?
When off (the default), Apple and apple are treated as the same item. Turn it on to compare exactly, including letter case.
Is my data sent anywhere?
No. The comparison happens entirely in your browser; nothing is uploaded.
Which spelling is shown when case is ignored?
The first one encountered in that list. Matching lowercases both sides to decide whether two entries are the same, but the output keeps the original text, so a list pasted from a spreadsheet comes back with its capitalisation intact rather than flattened.
Why does an item I can see in both lists show as only in one?
Almost always invisible whitespace — a trailing space from a copied cell, or a non-breaking space that a web page used instead of a normal one. Turn trimming on for the first case. For the second, the character is genuinely different, so it has to be replaced in the source.
Related tools
Semver Tools (Parser, Comparator, Bumper)
Parse, compare, and bump semantic versions side-by-side, with a range expander that shows what ^x.y.z and ~x.y.z actually cover.
Developer
Time Difference Calculator
Calculate the exact difference between two date-times, broken down into days, hours, minutes, and seconds.
Time
HTTP Headers Reference
Searchable reference for ~50 standard HTTP request, response, CORS, caching, security, and cookie headers.
Developer
Text Diff Viewer
Compare two pieces of text and see line-by-line or word-by-word additions and removals.
Text
Line Formatter — Add Prefix, Suffix & Join
Wrap each line with a prefix and suffix and join them with any separator, in your browser.
Text
Character & Word Counter
Count characters, words, sentences, lines, and bytes in real time.
Text