To compare two lists for duplicates means taking two separate line-based lists and finding which items appear in both, plus which items appear in only one of them. The fastest path is to paste List A and List B into a local set-operation tool, choose whether letter case changes membership, and read off five labeled sections at once: items in both lists (the duplicates), only in A, only in B, the union of both, and the symmetric difference (items in exactly one list). Each nonblank trimmed line counts as one member, blank lines are dropped, and the first spelling of each duplicate key is the one displayed. The operation happens entirely in your browser, so nothing is uploaded, stored, or sent to an AI. Limits are one million UTF-16 code units and 50,000 lines per list, and exceeding either produces an explicit error. Use this workflow for email lists, attendee rosters, inventory IDs, allowlists, URL collections, keyword sets, or any set comparison where one physical line equals one literal item under the chosen case rule.

Duplicates Within One List vs. Between Two Lists
A "duplicate" can mean two different things depending on context. Within a single list, a duplicate is the same value appearing twice or more in that one list; cleaning it up is the job of a single-line deduper such as a remove-duplicate-lines guide, which keeps the first occurrence of every line. Between two lists, a duplicate is an item whose membership key appears in both lists, which is the job the Compare Two Lists tool is built for. The two operations share the word "duplicate" but answer different questions, and using the right one matters. If your goal is to slim a single column before importing it somewhere, reach for the single-list deduper. If your goal is to reconcile a guest list against a registration export, find emails that exist in both an old and a new subscriber list, or compare two crawls of filenames for overlap, paste both columns into the compare tool and read the "In both" section.
Compare Two Lists for Duplicates Step by Step
- Prepare List A and List B in a plain text editor. Put one item per line: email addresses, SKU codes, attendee names, URLs, filenames, or any string where one line equals one comparison key.
- Open Compare Two Lists, paste List A into the List A field, and paste List B into the List B field. Paste directly from your source rather than retyping, so you do not introduce typos that would mask real duplicates.
- Choose your case-sensitivity policy. The default is case-insensitive, so Apple and apple share one membership key. Switch to case-sensitive if "John" and "john" should count as different members.
- Click Compare. Five labeled sections appear: IN BOTH, ONLY IN A, ONLY IN B, UNION, and EITHER NOT BOTH. IN BOTH is your direct duplicate answer.
- Read each section carefully. IN BOTH lists the items that appear in both lists, preserving the first spelling and order seen in List A. ONLY IN A and ONLY IN B are directional differences. UNION contains every member from both lists, ordered by first occurrence in A and then new members from B. EITHER NOT BOTH (the symmetric difference) contains items that appear in exactly one list.
- Copy the labeled report using the copy action. The clipboard receives five uppercase headings in a fixed order with LF-separated values, and an empty section is replaced by an em dash so absence stays visible.
- Paste the report into your destination system and verify the literal line policy before treating any result as authoritative. A downstream system with different normalization rules (Unicode confusables, lowercased emails, trimmed IDs) may merge members the tool treats as separate, or split members the tool treats as one.
The Five Views the Tool Returns
The five labels on the Compare Two Lists screen correspond to the standard set operations documented by MDN's JavaScript Set methods reference and Python's built-in set types. Each operation has a precise meaning and answers a different question about your two lists.
| Operation | Tool Label | Definition | Use It For |
|---|---|---|---|
| Intersection | IN BOTH | Members whose key is present in both A and B | Finding duplicates across two lists |
| A difference | ONLY IN A | Members in A but not in B | Spotting what is missing from B |
| B difference | ONLY IN B | Members in B but not in A | Spotting what is new in B |
| Union | UNION | Every distinct member from either list | Producing a combined unique list |
| Symmetric difference | EITHER NOT BOTH | Members in exactly one list | Finding items that need attention on either side |
For A containing apple, banana, pear and B containing banana, peach, the IN BOTH result is banana. ONLY IN A is apple and pear. ONLY IN B is peach. UNION is apple, banana, pear, peach. EITHER NOT BOTH is apple, pear, peach. The same arrays feed the visible panels and the copied report, so what you read is what you paste.
Case Sensitivity, Whitespace, and What Counts as a Duplicate
The tool normalizes each line before comparing. CRLF and standalone CR line endings become LF, surrounding whitespace is trimmed, and blank lines are discarded entirely. Whitespace inside a line is preserved after the surrounding trim, so "Project Alpha" and "Project Alpha" remain different members because their internal spacing differs. The chosen case rule applies consistently to deduplication and to every one of the five operations. In case-insensitive mode, Apple and apple share one membership key, and the first displayed spelling (Apple if Apple appears first in List A) is the one shown in IN BOTH and UNION. In case-sensitive mode, the same two lines are treated as different members and can both appear in the result. The tool does not parse CSV, split commas, normalize Unicode, remove punctuation, compare numbers numerically, resolve URLs, or perform fuzzy matching. One physical line is one literal item under the chosen case rule, so plan your input to match how your destination system normalizes the same items.
Input Limits and Error Handling
Each input textarea is bounded at one million UTF-16 code units and 50,000 lines. These bounds keep splitting, map construction, rendering, and clipboard output predictable across browsers. If both normalized lists are empty, or either limit is exceeded, the tool returns an explicit error rather than partial results. The error does not include a partial report, so the comparison is treated as not yet performed. If you regularly hit these limits, the cleanest move is to split your lists with the Text File Splitter, compare each pair, and rejoin the labeled sections with the Text File Merger, both of which run locally. Editing either textarea clears the prior result, so re-run the comparison after every paste change to see updated outputs.
Practical Situations Where Duplicate Detection Matters
Duplicate detection between two lists is one of the most common data-cleanup tasks. A few examples that fit cleanly inside the tool's design:
- Email marketing. Paste your old subscriber export into A and a fresh opt-in list into B. IN BOTH tells you who is already on your list, while ONLY IN B is the clean net-new segment for the next campaign.
- Inventory and SKUs. Paste warehouse A's stock codes into A and warehouse B's codes into B. ONLY IN A is stock that needs to be transferred, and ONLY IN B is stock that already exists at the destination.
- Event rosters. Paste the registration system export into A and the security check-in list into B. IN BOTH is everyone registered, and ONLY IN B is walk-ins or staff.
- Allowlists and blocklists. Paste your current allowlist into A and a candidate additions file into B. IN BOTH is already covered, so skip it; ONLY IN B is what you actually need to add.
- Migration checks. Paste the source-system IDs into A and the destination-system IDs into B. The symmetric difference (EITHER NOT BOTH) reveals every ID that exists on exactly one side, which is the first place to look when reconciliation totals do not match.
- Filename or URL cleanups. Paste two crawls of the same directory into A and B. UNION is the complete set of files touched across both crawls, and IN BOTH is the overlap.
Privacy and Local Processing
Every operation runs in your browser. The textareas, the normalization pass, the set calculations, the rendering of the five panels, and the clipboard write happen on the local device. No input or result is uploaded, stored, logged to a comparison service, or sent to an AI model. Clipboard success is reported only after the browser confirms the write; if the browser denies clipboard permission, the tool surfaces a manual-copy instruction instead of pretending the copy succeeded. The implementation uses stable JavaScript map objects rather than the newest native Set methods, which avoids a browser-compatibility dependency while preserving the same set semantics documented by MDN and the Python standard library. For work that involves sensitive lists such as customer rosters or internal IDs, the local-only design means a third-party comparison service never sees a single line of your data.