About Text Cleaner
Text copied out of spreadsheets, PDFs, chat apps and web pages tends to arrive with stray spaces, empty lines, repeated entries and invisible characters that break searches and imports. Tick the clean-ups you want and the result updates as you type.
Each step works line by line and runs in a fixed order, so you always know what you will get. Line endings are kept as they were, so a Windows file stays a Windows file.
How it works
- The text is split into lines at any kind of line break, and the ending used in the input is used again in the output.
- Clean-ups run in this order: non-printing characters, trimming, collapsing spaces, empty lines, duplicates, and finally the line order.
- Duplicates are compared after the earlier steps, keeping the first occurrence. Accented letters typed in different ways count as the same.
- Sorting uses your browser language rules, so accented letters sort next to their base letter. Shuffling uses the browser secure random generator.
Questions
Which non-printing characters are removed?
Control characters other than the tab, zero-width spaces, word joiners, soft hyphens, direction marks and stray byte-order marks. Zero-width joiners stay, because emoji such as family groups and several scripts need them.
Does the order of the steps matter?
Yes, and it is always the same: lines are trimmed and spaces collapsed before blank lines and duplicates are judged, so "apple " and "apple" count as duplicates once trimming is on. Sorting comes last.
What does natural order do differently?
It reads runs of digits as numbers, so "file 2" comes before "file 10". Plain A to Z compares character by character and puts "file 10" first.
How much text can it handle?
Up to 5 MB, which is several hundred thousand lines. Everything happens in this browser tab; nothing is uploaded.
Everything you enter here is processed in this browser tab. Nothing is uploaded, logged or shared. How privacy works here.