Skip to content
GAMETROZ

Remove Extra Spaces

Collapse repeated spaces and tabs, trim every line and clean up blank lines.

Processed locally in your browser.

About Remove Extra Spaces

Text copied from PDFs, emails and spreadsheets often arrives with double spaces, stray tabs and broken lines. Cleaning it by hand is tedious and easy to miss.

Runs of spaces, tabs and non-breaking spaces become a single space, and each line is trimmed. Blank lines are kept unless you ask for them to be removed, and joining lines turns a hard-wrapped paragraph back into one line of text.

How to use Remove Extra Spaces

  1. 1Paste the text you want to clean.
  2. 2Choose whether to remove empty lines or to join all lines into one paragraph.
  3. 3Read the summary to see how many characters, empty lines and line breaks were removed.
  4. 4Copy the cleaned text or clear the box.

Examples

Input

  Hello    world 	 from   here  

Result

Hello world from here
Spaces and tabs collapsed, line trimmed.

Input

Line one

  line   two
line three

Result

Line one line two line three
With Join lines into one switched on.

Frequently asked questions

Does it remove spaces between words completely?

No. Several spaces in a row become exactly one, so words stay separated. Only whitespace at the start and end of each line is removed entirely.

Does it change non-breaking spaces?

Yes. Non-breaking spaces and other Unicode space characters count as spaces and are collapsed into a normal space, which is usually what you want when cleaning pasted web text.

Guides

Tools guide

How to Count Words and Characters in Any Text

Know the difference between word and character counts, check limits such as 160-character texts and 280-character posts, and tidy text before you count.

· 3 min read