Trim Whitespace

Trim leading and trailing spaces from every line, squeeze repeated spaces and turn tabs into spaces.

Free · No upload · 100% on your device

How to use Trim Whitespace

  1. Type or paste your text.
  2. Choose the settings in the side panel. The result updates as you type.
  3. Copy the result or download it as a file.

Private by design. Everything you type, open or record is processed in this browser tab and is never uploaded to KittySuite.

About Trim Whitespace

Trailing spaces are invisible but break comparisons in spreadsheets and code. Choose whether to trim the start, the end or both sides of each line; “Squeeze inner spaces” turns runs of spaces into one.

Everything runs in this browser tab: your text is never uploaded or stored, and the result updates as you type. It keeps working offline once the page has loaded.

Trim Whitespace: frequently asked questions

How do I remove trailing spaces from every line?

Paste the text and choose to trim both sides, only the start or only the end.

Why do trailing spaces matter?

They are invisible but break comparisons in spreadsheets and code.

Can I turn tabs into spaces?

Yes. Turn on “Turn tabs into spaces”. “Squeeze inner spaces” also turns runs of spaces into one.

Are blank lines removed?

Only at the very start and end of the text, by default.