Deduplicate List
Removes duplicate items from a list of lines, emails or comma separated values. It can also show only the items that repeat, with how many times each appears, or only the items that appear once.
- Runs in your browser
- Nothing uploaded
- Free, no sign-up
One item per line, or pick another separator below. You can also drop a text file here.
Your list is processed in this browser tab and is not uploaded.
How to Use Deduplicate List
- Paste your list, open a text file, or drop one on the box. Pick the separator if items are not one per line.
- Choose What to keep: each item once (first or last copy), only items that repeat, only items that appear once, or a cleanup of repeats that sit next to each other.
- Decide how strict the match is: ignore upper and lower case, ignore spaces at the ends, and drop empty items.
- Copy the result or download it as a .txt file. The table under the tool lists every repeated item and its count.
Example: cleaning a mailing list
This list was pasted from two sign-up sheets. Some names and emails were typed with different capitals, one has a trailing space, and there is a blank line:
Ana
[email protected]
ana
Carlos
[email protected]
dana
carlos
ana
With the default settings (keep the first copy, ignore case, ignore spaces at the ends, drop empty items) the result is:
Ana
[email protected]
Carlos
dana
The status line reads: 9 items in, 4 out. 4 removed (50%). 4 different items, 3 of them repeat. 1 empty dropped. Switch What to keep to Only items that repeat and the output becomes a count of the culprits:
Ana (3)
[email protected] (2)
Carlos (2)
Only items that appear once gives dana, the one contact that was not entered twice.
Which option gives which result
All six options run on the same eight items, a a b a a a c c. The last column shows the command line tool that gives the same answer, in case you need it in a script.
| What to keep | Result | Same as |
|---|---|---|
| Each item once, keep first copy | a, b, c | awk '!seen[$0]++' |
| Each item once, keep last copy | b, a, c | tac | awk '!seen[$0]++' | tac |
| Only items that repeat (with counts) | a (5), c (2) | sort | uniq -d (sorted, no counts) |
| Only items that appear once | b | sort | uniq -u |
| Remove repeats next to each other | a, b, a, c | uniq |
| At most 2 repeats in a row | a, a, b, a, a, c, c | no single command |
Keeping the last copy matters when the list is in time order and the newest entry is the one you trust. The two “in a row” options leave the order alone and only touch runs, which suits log files and sensor readings where the same value can come back later.
How it works
- The text is split into items by the separator you choose. A final line break does not create an extra empty item.
- Each item gets a comparison key. Ignoring case lowercases the key, ignoring spaces trims it, and the Unicode option converts it to NFC, so an “é” typed as one character matches an “e” followed by a combining accent.
- Only the key is changed. The item you see in the result is the original text of the copy that was kept, which is why the first example keeps “Ana” with a capital.
- Counts in the report and in the “(3)” suffix always refer to the whole list, not just a run.
- Sorting uses natural order, so item2 comes before item10.
Limits
- Items are compared as whole values. “Ben” and “Ben Smith” are different items, and the tool does not guess near matches or typos.
- For CSV rows it compares the full row. To remove rows that share one column, extract that column first, or sort the file in a spreadsheet.
- Text is processed in the browser, so very large files (hundreds of MB) are better handled with the commands in the table. A 200,000 line list takes well under a second here.
Frequently asked questions
How do I remove duplicates but keep the original order?
Leave Order on Original order, which is the default. The first copy of each item stays where it was and later copies are removed, so nothing gets shuffled.
How can I see which items are duplicated and how many times?
Pick Only items that repeat. Each repeated item is listed once with its total count, for example “apple (3)”. The table under the tool shows the same counts, sorted from most to least repeated, and Copy report gives them as tab separated text for a spreadsheet.
Why were “Apple” and “apple” treated as the same item?
Ignore upper and lower case is on by default because most lists of names, tags and emails should match that way. Turn it off when capitals carry meaning, such as product codes or passwords.
Is there an Excel formula for this?
In Excel 365 and Google Sheets, =UNIQUE(A1:A100) keeps one copy of each value, and =UNIQUE(A1:A100,,TRUE) returns only the values that appear exactly once. This page gives the same results without a spreadsheet and adds counts, case options and the in-a-row cleanups.
Keep working with your list
Count List Items →
Count list items with frequency analysis, duplicates, unique-only output, TSV export. Free, client-side, instant.
Compare Two Lists →
Paste two lists to see what is only in list A, only in list...
Alphabetize List Sort Items Online | A-Z →
Alphabetize list items instantly. Sort A-Z or Z-A, case-sensitive or not. Remove duplicates option....
Related Tools
Add List Prefix - Prepend Text →
Adds the same text before or after every item in a list, wraps items…
Alphabetize List Sort Items Online | A-Z →
Alphabetize list items instantly. Sort A-Z or Z-A, case-sensitive or not. Remove duplicates option.…
Change List Length →
Change List Length Truncate, pad, or cycle any list to a target length. Free,…
Change List Separator →
Change List Separator and Convert list separators between newline, comma, tab, semicolon, pipe, and…
Chunk List Text →
Split any list into fixed-size chunks with line/numbered/labeled/custom-separator output. Live preview, keep-or-drop trailing chunk.…
Colorized List Item →
Colorized list item online. Turn any list text into a colour-coded HTML block with…
Convert List to Columns →
Arrange list items into 2-10 monospace-aligned columns with horizontal or vertical fill. Free, offline,…
Convert List to Image →
Turn a text list into a PNG or JPEG image with custom fonts, colors,…
Count List Items →
Count list items with frequency analysis, duplicates, unique-only output, TSV export. Free, client-side, instant.
Create Custom List →
Generate custom numbered lists with 10 placeholders: {n}, {upper}, {roman}, {hex}, {bin}, {oct}, etc.…
Create Random List →
Generate random lists - numbers, words, letters, UUIDs. Math.random or cryptographically secure RNG. 6…
Create Symmetric List →
Mirror a list to create symmetric patterns - full mirror, palindrome, or bi-mirror. JSON,…