Remove All Whitespace

Strip every space, tab and line break to produce one unbroken string.

Text
No whitespace
Runs locally in your browser

About the Remove All Whitespace

Sometimes whitespace is not formatting but noise. A SHA-256 digest copied out of a terminal wraps across two lines, a base64 payload arrives with a space every 76 characters, a licence key is printed in groups of five. Compare any of those against the original and they differ, even though the meaningful characters are identical. This tool deletes every whitespace character and returns one unbroken string.

Everything the Unicode standard classes as whitespace goes: spaces, tabs, carriage returns, line feeds, non-breaking spaces, the narrow no-break space that creeps in from typography, and the ideographic space from CJK input. Zero-width characters are the exception, because they count as formatting marks rather than whitespace, so a zero-width joiner or a byte order mark survives and can still break a comparison.

This is deliberately destructive. Words run together, lines merge, and nothing in the output records where the structure used to be, so keep the original before you run it. For readable text where single spaces and line breaks should stay, Remove Extra Spaces is the tool you actually want, and Trim Lines if only the ends of lines are the problem.

How to use

  1. Paste the text.
  2. Copy the whitespace-free result.
  3. Use the gentler Remove Extra Spaces if you want to keep single spaces.

Common questions

Does it remove line breaks too?
Yes, every whitespace character including spaces, tabs and newlines is removed.
What about non-breaking spaces?
Yes, Unicode whitespace including non-breaking spaces is removed.
Will it merge words?
Yes, words run together since the spaces between them are gone. That is the intended behaviour.