Remove Duplicate Lines Text
Strip repeated lines from a list, keeping the order you had.
Remove Duplicate Lines is a free online tool that strip repeated lines from a list, keeping the order you had. It runs entirely in your web browser using plain JavaScript, so files are processed on your own device and never uploaded to a server. There is no sign-up, no file size limit imposed by the site, no watermark and no paid tier.
- Price
- Free — no account, no quota, no watermark
- Category
- Text
- Where it runs
- In your browser, on your device
- Files uploaded
- None
- Technology
- plain JavaScript
- Settings
- 3
- Works offline
- Yes, after the first visit
About Remove Duplicate Lines
Remove Duplicate Lines is one of 57 text tools on DuckyTools, and like all of them it runs entirely inside this page. Strip repeated lines from a list, keeping the order you had.
How to use it
- Paste the text you want to run through remove duplicate lines.
- Set ignore case, ignore surrounding spaces and sort the result.
The 3 settings
| Setting | What it does | Default |
|---|---|---|
| Ignore case | On or off. Off by default. | Off |
| Ignore surrounding spaces | On or off. On by default. | On |
| Sort the result | On or off. Off by default. | Off |
Under the hood
| Runs on | plain JavaScript — runs the whole thing |
| Controls | Ignore case, Ignore surrounding spaces, Sort the result |
Questions
Does it keep the first or the last occurrence?
The first, with the original order preserved. Tick "Sort the result" if you would rather have it alphabetised.
Why are two lines that look identical not being removed?
Usually trailing whitespace or a different case. Turn on "Ignore surrounding spaces" and "Ignore case" and they will collapse. Invisible characters pasted from a spreadsheet can also do it.