ToolsEssential

Remove Duplicate Lines

Paste a list with one item per line. Duplicates are removed instantly while keeping the original order — or sort the result if you prefer.

Runs in your browserFree, no sign-upNo watermark
0Lines in
0Lines out
0Removed

How to remove duplicate lines

  1. Paste your list into the left box, with one item per line. You can copy a column straight from Excel or Google Sheets.
  2. Choose your options: ignore case, trim spaces, remove empty lines, and whether to sort the result.
  3. The cleaned list appears on the right immediately. Copy it or download it as a text file.

What the options do

Ignore case

When ticked, “Apple”, “apple” and “APPLE” are treated as the same line, and the first one that appears is kept. Leave it unticked if capital letters matter, for example with passwords or case-sensitive codes.

Trim spaces

Spaces at the start or end of a line are invisible but make two lines different. Lists copied from spreadsheets and PDFs often contain these. Trimming removes them before comparing, so “ banana” and “banana” become duplicates.

Remove empty lines

Deletes blank lines so your output is a tidy, continuous list.

Sorting

By default the tool keeps the original order and keeps the first occurrence of every item — important when the order means something, such as a ranked list. You can instead sort alphabetically (A→Z or Z→A), numerically (so 2 comes before 10) or by length.

Everyday uses

  • Email and contact lists: remove repeated addresses before sending a newsletter so nobody gets the same email twice.
  • Keyword research: merge keyword exports from several tools and remove overlaps.
  • Product SKUs and order IDs: find the unique values in a long export.
  • Log files: collapse repeated error lines to see the distinct problems.
  • Names and attendance: clean a sign-up sheet where people registered twice.

Removing duplicates in Excel vs. here

Excel’s “Remove Duplicates” button works on whole table rows and changes your original sheet. This tool works on plain text lines, never touches your original file, and lets you see exactly how many lines were removed. For a quick clean of one column, copying the column here and pasting the result back is often faster.

Tip: finding what was removed

Want to know which items were duplicated? Paste your original list into our Text Compare tool on one side and the cleaned list on the other — the removed lines are highlighted.

Frequently asked questions

Does it keep the first or the last duplicate?

It keeps the first occurrence of each line and removes later repeats, so the original order is preserved.

How many lines can I process?

Hundreds of thousands of lines work fine on a modern device, because everything runs in your browser with no upload.

Can I remove duplicates from a CSV file?

Yes, as long as each record is on its own line. The whole line is compared, so two rows are only duplicates if every column matches.

Is my list private?

Yes. The list is processed locally in your browser and never uploaded.

What does “numbers ascending” sorting do?

It sorts lines by their numeric value, so 2 comes before 10. Lines that are not numbers are placed at the end in alphabetical order.

More text tools

See all →