Home › Text Tools › Compare Two Lists

Compare Two Lists

Paste two lists, one item per line or separated by commas, and instantly see what is only in list A, only in list B, in both lists, and in either. Options for case, spaces and sorting make it easy to compare emails, SKUs, names or IDs.

Last updated:

A Only in A (missing from B)

0

B Only in B (missing from A)

0

A∩B In both lists

0

A∪B In either list (union)

0

Each result lists an item once. Duplicates inside a list are counted in the summary above each box.

Advertisement
Advertisement

How to use the Compare Two Lists

  1. Paste list A in the left box and list B in the right box, one item per line or separated by commas.
  2. Pick the separator or leave it on Auto-detect.
  3. Set the matching options: ignore case, trim spaces and skip empty items.
  4. Read the four results: only in A, only in B, in both and in either list. They update as you type, or press Compare lists.
  5. Sort, copy or download any result, with the output separator you prefer.

What each result means

Comparing two lists is set logic. Treat list A and list B as sets of distinct items, then:

ResultSet nameNotationTypical use
Only in ADifference A minus BA \ BCustomers who did not reorder, files missing from a backup
Only in BDifference B minus AB \ ANew sign-ups since the last export, newly added SKUs
In bothIntersectionA ∩ BEmails on two mailing lists, students in both classes
In eitherUnionA ∪ BMerge two lists into one without duplicates

Only in A plus Only in B is the symmetric difference: everything that is not shared. The overlap percentage in the summary is the Jaccard index, |A ∩ B| ÷ |A ∪ B|: 100% means the lists hold the same items, 0% means nothing is shared.

Tips for accurate list comparisons

  • Ignore case for emails, domains and usernames, where uppercase and lowercase usually mean the same thing.
  • Keep Trim spaces on when data comes from spreadsheets or PDFs: a hidden trailing space is the most common reason two identical-looking items do not match.
  • Numbers are compared as text, so 007 and 7 are different items. Format both columns the same way before copying.
  • Sorting A to Z is number aware, so item2 comes before item10.
  • To compare whole documents line by line in order, use a text diff tool instead; this tool ignores order and position.

Frequently asked questions

How do I find the differences between two lists?

Paste one list into List A and the other into List B. The Only in A box shows items that are missing from B, and the Only in B box shows items that are missing from A. Together they are the full difference between the lists.

How do I find the items that appear in both lists?

Look at the In both box. It lists every item found in A and in B, which is called the intersection of the two lists. Each common item is listed once, even if it repeats.

What is the union of two lists?

The union is every distinct item that appears in at least one of the lists, with duplicates removed. The In either list box shows it, so you can use it to merge two lists without repeats.

Does the comparison ignore uppercase and lowercase?

Only if you tick Ignore case. Then Apple, apple and APPLE count as the same item, and the results show the spelling that appeared first. With the box unticked, the comparison is exact.

What happens to duplicate items inside a list?

Duplicates are counted and shown in the summary under each list, but every result lists an item only once. To clean a single list, use a duplicate remover.

Can I compare two columns from Excel or Google Sheets?

Yes. Copy a column and paste it into List A, then copy the other column into List B. Cells arrive one per line, so the New line or Auto-detect separator works directly.

Is my data uploaded anywhere?

No. The lists are compared by JavaScript in your browser and are never sent to a server, so it is safe for customer emails, order numbers and other private data.

Are all the tools on FreeToolCabin tested for quality and accuracy?

Yes! Every tool on our site undergoes automated Q/A testing in real browser environments to ensure high precision, correct output, and zero errors. If you happen to spot a bug or have a suggestion, please contact us at [email protected] and our team will review it right away.

Related tools

Remove Duplicate LinesDelete duplicate lines from any list, ignoring case or spaces, keep first or last, and sort.Text CompareFind the differences between two texts.Sort Lines AlphabeticallySort a list A-Z, Z-A, numerically, naturally or by length, or shuffle it.CSV Diff CheckerCompare two CSV files by key column and see added, removed and changed rows cell by cell.Combinations GeneratorList every k-combination of your items, with or without repetition, and copy or export them.Folder Compare ToolCompare two folders by file list, size and SHA-256 hash, then open a text diff of changed files.Glob Pattern TesterTest glob patterns like **/*.js, {a,b} and !exclusions against a list of file paths.Set CalculatorUnion, intersection, difference and complement of up to 4 sets, with a Venn diagram and counts.Online Word ProcessorFree browser word processor with headings, lists, tables and images. Autosaves; export DOCX or PDF.Remove Line BreaksStrip line breaks and extra spaces, keep paragraphs if you want.Case ConverterConvert text to UPPERCASE, lowercase, Title Case, camelCase and more.MLA Format GeneratorBuild an MLA 9 heading, title page layout and Works Cited entries.Lorem Ipsum GeneratorGenerate placeholder text as paragraphs, words or lists, with HTML.Text RepeaterRepeat any text or emoji up to 100,000 times with custom separators.Find and Replace TextFind and replace words or regex patterns in any text, with match highlighting and undo.Add Line NumbersNumber every line of your text with custom start, step, padding and separator, or remove numbers.Add Prefix and Suffix to LinesAdd text to the start and end of every line: quotes, commas, bullets or SQL lists.Comma SeparatorTurn a column of lines into a comma separated list and back, with any delimiter.Text to Handwriting ConverterTurn typed text into realistic handwriting on notebook paper and save it as PNG or PDF.Japanese Kana ConverterConvert romaji to hiragana or katakana, kana to romaji, and hiragana to katakana instantly.Pinyin Tone ConverterTurn pinyin tone numbers (ni3 hao3) into tone marks (nǐ hǎo), or tone marks back into numbers.Remove Extra SpacesClean up double spaces, tabs, blank lines, non-breaking and invisible spaces in one click.Random Word GeneratorGenerate random English words by type, length, first letter and syllables, then copy them.List RandomizerShuffle a list into random order, pick random items or split it into fair teams.Email ExtractorPull every unique email address out of text or files, sort, filter by domain and export CSV.URL ExtractorExtract every link from text or HTML, remove duplicates, filter by domain or protocol.Strip HTML TagsRemove HTML tags and get clean plain text with line breaks and decoded entities.Online NotepadPrivate notepad that autosaves notes in your browser, with find, word count and .txt download.Remove PunctuationStrip all or only selected punctuation from text, with smart options for apostrophes and numbers.Text SplitterSplit long text into chunks by characters, words, lines or a delimiter, with numbering and copy.Remove AccentsStrip accents and diacritics from text (é→e, ñ→n, ß→ss, ø→o) instantly, live as you type.Sort NumbersPull numbers out of any text and sort them ascending or descending, with sum, average and median.Thread SplitterSplit long text into numbered X, Threads, Bluesky or Mastodon posts at sentence boundaries.Duplicate Word FinderFind repeated words in your text: doubled words like "the the" and overused words, highlighted.Alternating Caps GeneratorTurn text into aLtErNaTiNg caps, random caps or alternating words, then copy it.Random Paragraph GeneratorGenerate readable random English paragraphs by topic and length for writing and design.Random Sentence GeneratorGenerate random grammatical sentences: simple, compound, complex and questions.Markdown to Plain TextStrip Markdown syntax and keep clean plain text with lists, line breaks and link URLs.Return Policy GeneratorCreate a return and refund policy for your store as text or HTML, with a refund example.Screenplay FormatterType a script in plain text (Fountain) and get a properly formatted screenplay, page count and PDF.Word ChangerSwap words for synonyms in your text, then click any word to cycle through alternatives.Words That End WithFind English words ending in any letters or suffix, filtered by length and sorted by score.Annotated Bibliography GeneratorBuild an APA or MLA annotated bibliography with hanging indents and download it as DOCX.EPUB to Text ConverterExtract plain text from EPUB e-books, pick chapters, count words and download a TXT file.Extract Dates from TextFind every date in text, in any common format, and convert them all to one format you choose.Extract Text Between DelimitersPull out every piece of text between brackets, quotes, HTML tags or your own start and end markers.Recipe Shopping List GeneratorPaste several recipes and get one combined grocery list with merged amounts, by store section.One Word Per LineSplit any text into a list with one word per line; strip punctuation, dedupe, lowercase and sort.Recipe FormatterPaste a messy recipe and get clean ingredients, numbered steps, scaling and a printable card.Remove Words from TextDelete a list of words or phrases from any text and see how many times each one was removed.Reverse Line OrderFlip the order of lines, list items or paragraphs so the last becomes first.Pairwise Sequence Alignment ToolAlign two DNA or protein sequences, global (Needleman-Wunsch) or local (Smith-Waterman), with identity %.Sort Lines by LengthSort lines from shortest to longest or the reverse, with ties sorted A-Z and lengths shown.Sort Words AlphabeticallyPut the words in any text in A-Z or Z-A order, remove duplicates and pick a separator.Sentence SplitterSplit text into one sentence per line, smart about abbreviations, decimals and quotes.Text to Table ConverterTurn tab, comma, pipe or space separated text into a table to copy as rich text, Markdown or plain text.Text TruncatorShorten text to a character, word or sentence limit without cutting words, with an ellipsis.Bulk Find and ReplaceApply a whole list of find → replace pairs to your text at once, with a per-pair change log.Contraction ConverterExpand contractions (don't → do not) for formal writing or contract phrases for a casual tone.Count Duplicate LinesCount how many times each line appears, sorted by frequency, with duplicates-only and CSV export.Double Space TextAdd blank lines between lines or paragraphs (1.5, double, triple spacing) or remove them again.Em Dash ReplacerReplace em and en dashes with commas, hyphens or periods and normalize ellipses and fancy punctuation.Extract Domains from URLsPull hostnames or root domains out of URL lists, strip www, dedupe and count links per domain.List to Sentence ConverterTurn a list into a natural sentence with commas and “and” or “or”, with an Oxford comma toggle.Merge Lines Side by SideCombine two to four lists line by line with any separator, padding or filling uneven lengths.Remove Line NumbersStrip leading numbers like 1., 1), [1] or code line numbers from every line and keep the text.Remove Stop WordsStrip common stop words (the, and, of…) from text in 7 languages to reveal the keywords.Remove Text in BracketsDelete everything inside ( ), [ ], { }, < > or custom markers, with nested bracket support.
See all 96 Text Cleaning & Formatting →