Text cleaner & line tools. One click, one clean list.
Runs entirely on your device, nothing is uploaded anywhere.
Split turns each delimiter into a new line. Use \t for tab, \n for newline.
How to use the Text Cleaner & Line Tools
This tool applies one cleanup operation at a time to the text in its editor: sorting, removing duplicates, trimming, changing case, numbering, adding a prefix or suffix, joining, splitting, and find and replace. Most operations work line by line, and every change can be undone. It suits anyone tidying lists, CSV columns, keyword sets or copied text.
Step by step
-
Paste your text
Paste or type into Your text. The counters below it show lines, words and characters. Reset brings back the box as it was after your first change: the whole text if you pasted it, but only the first character if you typed it.
-
Sort and order lines
Use Sort A→Z or Sort Z→A for alphabetical order that ignores case, Sort numeric to sort by the number each line starts with, Reverse to flip the order, or Shuffle for a random order.
-
Clean up lines
Remove duplicates keeps the first copy of each identical line. Remove empty lines drops blank ones, Trim each line strips spaces at both ends, Collapse spaces turns runs of spaces or tabs into one space, and Collapse blank lines leaves at most one blank line in a row.
-
Change case
Press UPPER, lower, Title Case or Sentence case. Each works on the whole text, including letters with accents. Title Case and Sentence case lowercase every other letter first, so an acronym such as NASA becomes Nasa or nasa.
-
Number and wrap lines
Add line numbers puts 1., 2., 3. at the start of each line, padded so they line up. Type a Prefix, a Suffix or both and press Apply to add them to every line.
-
Join or split
Join turns all lines into one, separated by the text in Join with, a single space by default. Split starts a new line at every match of Split by, a comma by default. Type \t for a tab or \n for a new line in either box. Split keeps any space that followed the comma, so run Trim each line afterwards.
-
Find and replace
Type in Find… and Replace with…, then press Replace all. Ignore case is on by default. Tick Regex to use a JavaScript regular expression, where $1 in the replacement inserts the first captured group.
-
Undo, copy or save
Undo steps back through your last 50 operations and Reset returns to your first text. Copy puts the result on the clipboard, Download .txt saves cleaned-text.txt, and Clear all empties the editor.
Reading the result
- The counters show lines, words and characters for the current text. An empty editor counts 0 lines, and any text counts at least 1.
- When an operation changes nothing, the text stays as it is and nothing is added to the undo history. Replace all also shows No matches found when the search text is not there.
- Sort numeric reads the number at the start of each line, so 10 apples sorts after 9 pears. Lines that do not start with a number go to the end in alphabetical order.
Tips and common mistakes
- Remove duplicates only removes exact copies, so Apple and apple, or a line with a trailing space, count as different. Run Trim each line and lower first for a stricter cleanup.
- Operations act on the whole text, not on a selection. To change only part of it, clean that part separately and paste it back.
- Plain find treats dots, brackets and other symbols literally. Only tick Regex when you mean to use a pattern; an invalid pattern shows an error and changes nothing.
- Shuffle uses the browser's ordinary random function. It is fine for mixing a list but not for draws that must be provably fair.
- Clear all also forgets your original text and the undo history, so use Undo or Reset first if you might want something back.
Privacy and limits
Every operation runs in your browser. Your text is not uploaded or saved, and the undo history lives only in the open tab, so closing it clears everything.
One editor, every text chore.
Frequently asked questions.
Is the Text Cleaner free?
Is it private? Is my text uploaded anywhere?
Does it work offline?
How does find & replace with regex work?
Can I undo an operation I didn't mean to run?
How do I split on a tab or newline?
Published · Last updated .