About this tool
Delete repeated lines and keep only the first occurrence of each.
Remove Duplicate Lines deletes repeated lines from a block of text and keeps only the first occurrence of each, leaving the surviving lines in their original order. It compares whole lines exactly as typed, with an optional Ignore case toggle that treats "Delhi" and "delhi" as the same line. Useful for anyone cleaning up an email list, a log file, a keyword dump or a pasted CSV column before importing it somewhere else.
Open Remove Duplicate Lines on AltFTool — it loads instantly in your browser.
Paste or type the text you're working with.
Choose how it should be transformed or analyzed.
Copy the finished text into your document or post.
Order is preserved exactly as pasted — nothing is sorted or shuffled, so the surviving lines stay where you expect them.
Leave the toggle off for an exact match, or turn on Ignore case so differences in capitalisation count as the same line.
Comparison is on the entire line, so two rows of a pasted CSV only collapse when every field matches.
No. The first occurrence of each line stays in its original position and later copies are dropped, so the output keeps your input order. If you want alphabetical order, sort the result afterwards in a separate step.
Only if you turn on the Ignore case toggle, which is off by default. With it off the comparison is byte-for-byte, so any difference in capitalisation makes the two lines distinct.
Blank lines are treated like any other line, so the first empty line is kept and every later empty line is removed. If you were using blank lines as paragraph separators, expect the spacing to collapse.
Almost always because of invisible characters — a trailing space, a tab, or a non-breaking space makes the lines different strings. Run the text through a space-trimming step first, then remove duplicates.