InputTestHub

Whitespace & Line Ending Inspector

Reports CRLF versus LF, trailing whitespace, mixed tab and space indentation, and normalises all of it in one pass.

Lab Nothing uploaded No sign-up Free, unlimited
Lab tool
Paste something on the left to see the result.
In short When an entire file shows as modified in a diff and you only changed one line, the cause is almost always line endings — your editor saved LF where the file had CRLF, or the reverse, and every line now differs. This reports which endings a file uses, whether they are mixed, where trailing whitespace sits and whether indentation mixes tabs and spaces, then normalises all of it in one pass. The permanent fix for the diff problem is a `.gitattributes` file declaring `text=auto` rather than each person configuring their editor, because that puts the rule in the repository where it survives new contributors. Trailing whitespace matters less than people argue about but is not entirely cosmetic: it produces noise in diffs, it is significant inside Markdown where two trailing spaces force a line break, and it can break here-documents and YAML in ways that are painful to debug. Mixed indentation is the one that causes real bugs — Python treats a tab as a different indent level from spaces, YAML rejects tabs outright, and a file that looks correctly aligned in one editor can be structurally wrong in another because the two render tab stops differently.

How to use the Whitespace & Line Ending Inspector

  1. Paste your text into the input box on the left.
  2. Adjust the options above the box if you need a different behaviour.
  3. The converted text appears on the right; press Copy to put it on your clipboard.

About the Whitespace & Line Ending Inspector

The Whitespace & Line Ending Inspector reports CRLF versus LF, trailing whitespace, mixed tab and space indentation, and normalises all of it in one pass. It runs as plain JavaScript inside the page, which means there is no upload step, no queue and no size limit imposed by a server — the only limit is your own device.

What people use it for

  • Working out why a diff shows every line as changed.
  • Finding the mixed tabs and spaces breaking a Python file or a YAML config.
  • Cleaning a file before committing it.

Frequently asked questions

Why does my whole file show as modified in git?
Almost always line endings. One editor saved CRLF where the repository has LF, so every line differs. A <span class="mono">.gitattributes</span> file with <span class="mono">* text=auto</span> prevents it recurring.
Does trailing whitespace actually matter?
In Markdown, two trailing spaces mean a line break, so it is sometimes deliberate. Everywhere else it is noise that shows up in diffs and code review. Most linters flag it for that reason.
Is the Whitespace & Line Ending Inspector free?
Free, unlimited, and no email address required. You can use it a hundred times a day and nothing changes.
Is my data uploaded anywhere?
No. The Whitespace & Line Ending Inspector runs entirely in your browser using JavaScript. Because the work happens locally, the tool also keeps working if your connection drops, and closing the tab is all it takes to discard everything.
When would I actually need the Whitespace & Line Ending Inspector?
The jobs it is built for: working out why a diff shows every line as changed. Finding the mixed tabs and spaces breaking a Python file or a YAML config. Cleaning a file before committing it. It is built for exactly those cases rather than being a general-purpose tool with this bolted on.
Is there an app version?
Yes. The page is responsive and the tool works in Chrome, Safari, Firefox, Edge and Samsung Internet on both Android and iOS. There is no app to install and nothing to sign into.

Related lab tools

All 30
03

Mojibake Fixer

Repairs text mangled by the wrong character encoding — the "’" and "é" problem — by…

06

Sentence Rhythm Analyzer

Measures the variation in your sentence lengths — the thing that makes prose readable, which…

07

Recipe Scaler

Rescales every quantity in a recipe for a different number of servings, keeping fractions…

08

CSV Column Analyzer

Profiles every column of a CSV — type, blanks, distinct values, ranges — and flags the ragged…

09

Fuzzy Duplicate Finder

Finds lines that are nearly the same, not just identical — catching "Acme Ltd." against "Acme…

10

RTL and Bidi Text Checker

Shows how right-to-left text renders against how it is stored, and finds unmatched embeddings…