gizmobench
BrowseDaily

Remove Extra Whitespace

Remove extra spaces from pasted text while retaining ordinary word gaps. This preset normalizes line endings and no-break or unusual spaces, replaces tabs with one space, collapses repeated spaces and trims each line. It does not initially remove zero-width characters or all whitespace. Both the original and cleaned copy stay visible.

After0 characters

The cleaned text appears here as you type.

Nothing pasted yet.

Every step is optionalNothing is uploadedNo account, no size cap
Steps
5 on
Before
0
After
0
Changes
0

Paste text into the Before box. It stays there, and the cleaned copy appears in the After box.

Steps, in the order they run

Each one is a switch, and the number beside it is what that step changed in your text. The order is fixed and runs top to bottom, because cleaning is not order free: no-break spaces become ordinary spaces before repeated spaces are collapsed, and a hyphenated word is rejoined while the line break is still there to see.

0 to 10
  • Collapse spacesTwo spaces between words
    The quick brown
  • Windows line endingsCRLF, invisible in every editor
    2 line endings changed
  • Curly quotes and dashesStraightened to plain ASCII
    No change with these steps
What you cannot see is what breaks things. A no-break space looks exactly like a space and stops a line wrapping where it should. A byte order mark at the front of a paste turns into a stray character in a CSV. Windows line endings are invisible until a script reads the file and finds a carriage return on every line. Each of those is its own step here, with its own count, so you can tell what was in the text rather than guess.
Accuracy. Each step is listed in the order it runs and counts what it changed, so nothing happens that you cannot see. The original stays on screen until you copy the result, and every step can be switched off.

Common questions

How do I remove leading or trailing whitespace?
Trim each line removes its leading and trailing spaces and tabs. Collapse repeated spaces also reduces internal runs to one. Turn other steps off if you only want line-edge trimming.
How do I remove all whitespace?
Enable Remove every space to remove Unicode whitespace, including line breaks. Words then run together. Zero-width space and some controls need the separate Remove invisible characters step.
Does this remove hidden characters?
The preset converts unusual visible-width spaces such as NBSP but does not enable Remove invisible characters. Enable that step for its fixed set of hidden characters. ZWJ and ZWNJ are preserved.
Can I undo the cleaned output?
The Before box stays unchanged while you review the result. Once copied out, the original spacing cannot be reconstructed from cleaned text alone. Keep your source.

Each step is listed in the order it runs and counts what it changed, so nothing happens that you cannot see. The original stays on screen until you copy the result, and every step can be switched off.