Remove Duplicate Lines

Remove duplicate lines from any list, keeping the first occurrence.

Paste a list with repeated lines and remove the duplicates instantly. The first occurrence of each line is kept, and the tool reports exactly how many lines were removed.

Loading tool…

If the tool stays on this message, make sure JavaScript is enabled, then reload the page.

About Remove Duplicate Lines

Merge two mailing lists, export contacts from two apps, or scrape the same directory twice, and you end up with the same entries appearing again and again. Removing duplicates by hand across hundreds of rows is slow and error-prone; a spreadsheet formula works but takes setup. This tool does the whole job in one click: paste your list, one item per line, and every repeated line after its first appearance is dropped, leaving the original order intact.

The first occurrence of each line is always the one kept, which matters when your lists carry implicit priority, the topmost entry wins. A case-insensitive toggle treats 'Apple' and 'apple' as the same line for lists where capitalization is inconsistent, and the tool reports exactly how many lines were removed so you can verify the cleanup against your expectations.

This is the right tool when each entry lives on its own line: email lists, phone lists, URLs, product SKUs, one-per-line keywords. It won't sort anything, and it deliberately preserves your list's order, if your duplicates are words inside sentences rather than whole lines, the sibling remove-duplicate-words tool is the one you want.

How to use Remove Duplicate Lines

  1. Paste your list, one item per line.
  2. Toggle case-insensitive matching if needed.
  3. Click the dedupe button and copy or download the cleaned list.

Why use this tool?

  • Keeps the first occurrence in order
  • Shows exactly how many lines were removed
  • Optional case-insensitive matching

Tips for best results

  • Put your preferred version of the list first, the first occurrence of each line is the one kept.
  • Turn on case-insensitive matching for lists merged from sources with inconsistent capitalization.
  • Compare the 'lines removed' count against your expectation; a surprising number hints at formatting differences.
  • Run this before sorting a list, so the sort reflects the final clean set.
  • For CSV data, dedupe the pasted column, then reattach it to the rest of your rows afterward.

Frequently asked questions

Which duplicate is kept?
The first occurrence of each line is kept; later repeats are removed.
Does it sort the list?
No. The original order is preserved, only the repeats are dropped.
What does case-insensitive mean here?
With it on, lines like 'Apple' and 'apple' count as duplicates; with it off, only exact matches are removed.
Is there a size limit?
There is no artificial limit, though very large lists may take a moment in your browser.
Will it work on CSV data?
It works on whatever text you paste, matching whole rows. For the cleanest results, paste a single column at a time rather than full comma-separated rows.

Related tools