About the Invisible Character Detector
Some of the strangest bugs come from characters you cannot see. A zero-width space pasted from a web page breaks a string comparison, a non-breaking space stops a search from matching, a byte-order mark at the start of a config file makes a parser reject the first key, and a soft hyphen splits a word that looks whole. This detector scans every character in the text and lists each invisible or control character with its position and Unicode name, so the culprit stops being a mystery.
It recognises the usual suspects by code point: zero-width space, non-joiner and joiner (U+200B to U+200D), left-to-right and right-to-left marks, the word joiner and invisible operators (U+2060 to U+2063), the byte-order mark (U+FEFF), the soft hyphen (U+00AD), line and paragraph separators (U+2028 and U+2029), the no-break and narrow no-break spaces, the ideographic space, and every C0 and C1 control character apart from tab, newline and carriage return. Below the findings it prints a cleaned copy with the zero-width and control characters removed and the exotic spaces replaced by ordinary ones.
Use it when a value that looks identical to another still fails to match, when a filename or username refuses to validate, or before pasting text copied from a PDF, a chat app or a CMS into code. To see the code point of every character rather than only the invisible ones, the Unicode Code Point Finder lists them all; to strip all whitespace outright, Remove All Whitespace is the blunter tool.
How to use
- Paste the suspicious text on the left.
- Read the list of hidden characters with their positions and names.
- Copy the cleaned text printed below the findings.
Common questions
- Where do invisible characters come from?
- Mostly from copy and paste: web pages insert zero-width spaces to control line breaks, word processors add soft hyphens and non-breaking spaces, and some editors write a byte-order mark at the start of a file.
- Are tabs and line breaks reported?
- No. Tab, newline and carriage return are ordinary whitespace and are left alone; every other control character is listed.
- What does the cleaned text change?
- Zero-width characters, joiners, marks, the byte-order mark and control characters are removed; non-breaking, narrow and ideographic spaces become normal spaces. Visible text is untouched.
- Why does a non-breaking space matter?
- It looks like a space but is a different character (U+00A0), so searches for a phrase with a normal space will not find it and some parsers reject it in identifiers.