About Whitespace Visualizer
Two strings look the same but will not match. A CSV column has a phantom space. Code copied from a web page refuses to compile. The cause is often a character you cannot see: a no-break space, a zero-width space, a byte order mark or a direction mark.
Paste the text or open a file and every such character is marked in place, named, counted and located by line and column. Trailing spaces and line ending styles are shown too. A cleaned copy with the invisible characters removed and the odd spaces made plain is ready to copy in one click.
How it works
- The text is read one Unicode code point at a time. Tabs, unusual spaces (no-break, thin, em, ideographic and others), zero-width and joining characters, direction controls, control codes, tag characters and variation selectors are each marked where they sit.
- A table lists every kind found, with its code point, the marker used, how many there are and the line and column of the first one. Columns count code points, so an emoji counts once.
- Joiners and selectors that hold a real emoji together, such as the joiners in a family emoji or the tags in the Scottish flag, are counted separately and left alone.
- The cleaned text drops zero-width, direction, control, tag and stray selector characters, turns Unicode line separators into ordinary line breaks and, if you leave that option on, turns unusual spaces into plain ones.
Questions
Why does a carriage return never show when I paste text?
Browsers turn Windows line endings into plain line feeds when text is pasted or typed into a text box. To see the real line endings, open the file instead: the tool then reads its bytes exactly, including CRLF endings and any byte order mark.
What are tag characters and why does the tool show hidden text?
Tag characters are invisible copies of the ASCII letters. Outside emoji flags they have no visible use, but software still reads them, so they have been used to hide instructions inside ordinary-looking text. The tool spells out any it finds.
Will cleaning break my emoji or other languages?
No. Joiners and selectors that are part of an emoji are kept, and letters of every script pass through unchanged. Zero-width non-joiners are removed, though, and some Persian and Indic text uses them on purpose, so check such text before using the cleaned copy.
How much text can it examine?
Up to 1 MB of text or a text file of that size. Every character is counted and cleaned, but the marked view shows only the first 10,000 characters so the page stays responsive.
Everything you enter here is processed in this browser tab. Nothing is uploaded, logged or shared. How privacy works here.