Text Tools
Remove Extra Spaces
Clean up text that has picked up stray spacing — usually from copying out of a PDF or a formatted document. Repeated spaces collapse to one and lines are trimmed, but separate lines stay separate.
Note
Everything happens in your browser. Nothing you paste is uploaded or stored.
How to use this tool
- Paste the text you want to tidy.
- Choose how blank lines should be handled.
- The cleaned text appears below, with a count of the characters removed.
Notes and limitations
- Runs of spaces and tabs collapse to a single space, and each line is trimmed at both ends.
- Line breaks are preserved. The tool never joins separate lines into one paragraph, which is the behaviour that makes some cleaners unusable for lists.
- Non-breaking spaces pasted from web pages and word processors are treated as whitespace and collapsed too.
- The double space after a full stop, if you use one, will be reduced to a single space.
- Everything runs in your browser. Your text is never uploaded to a server, which matters when what you are working on is a draft, a client list or anything else you would rather not send anywhere.
Frequently asked questions
Will this join my lines together?
No. Line breaks are always kept. Only spaces and tabs within a line are collapsed.
Why does text copied from a PDF have odd spacing?
PDFs store the position of each character rather than the words, so extracting text reconstructs the spacing approximately. That often produces double spaces and stray line breaks.
Does it remove non-breaking spaces?
Yes. They are invisible but behave differently from ordinary spaces, and pasting them into code or a form is a common source of confusion.
Related tools
- Remove Duplicate LinesRemove repeated lines from a list, keeping the original order.
- Case ConverterConvert text between eleven case formats, including programming cases.
- Character CounterCount characters against common field and post limits.
- Word CounterCount words and characters with reading time, as you type.
- Sentence CounterCount sentences and see the average words per sentence.
- Paragraph CounterCount paragraphs and lines, with average paragraph length.