Invisible Text: What It Is, Where It Hides, How to Find It
Invisible text is text you cannot see on screen. It comes in two kinds. The first is made of real characters that draw nothing, such as the zero-width space. The second is made of ordinary letters that are hidden by formatting, such as white text on a white page. They behave differently, and the fix for one does not work on the other. This guide explains the types, what invisible text can and cannot do, and how to find it and remove it.
The four kinds of invisible text
People use the phrase for several different things. Which one you have decides how to deal with it.
| Kind | What it is | Examples | If you paste as plain text |
|---|---|---|---|
| Characters with no width | Format characters that give layout instructions and draw nothing | Zero-width space U+200B, word joiner U+2060, byte order mark U+FEFF | Still there |
| Characters that look blank | Letters, symbols and spaces that draw an empty gap or nothing | Hangul filler U+3164, braille pattern blank U+2800, no-break space U+00A0 | Still there |
| Tag characters | A block of characters, U+E0000 to U+E007F, that mirror plain letters and are drawn as nothing in most apps | The hidden part of some flag emoji, or a hidden copy of ASCII text | Still there |
| Text hidden by formatting | Ordinary letters that are styled so they do not show | White font on a white page, Word's Hidden font effect, a web page element that is not displayed | The text becomes visible |
The first three groups are all real characters, and our guide to the invisible character list has the codes. The last group is plain text with a disguise on it.
How to tell which kind you have
- Paste into a plain-text field. Use Notepad on Windows or a plain-text note on a Mac. If words you could not see before appear, the text was hidden by formatting.
- Select everything. Press
Ctrl+Aon Windows orCmd+Aon a Mac. Text that is white on white is highlighted when selected, so it shows up. - Walk the cursor through the text. Click at the start of a line and press the right arrow key. If the cursor seems to pause while nothing moves, it just stepped over a character you cannot see.
- Compare the counts. If a counter says 120 characters and you can only see 111, something invisible is taking up the difference.
- Paste into the cleaner. The AI Text Cleaner lists the zero-width characters, special spaces, control codes and tag characters it finds, with a code, a name and a count for each.
What invisible text can do
- Control layout. A zero-width space marks a place where a long string may break onto the next line. A word joiner stops a break. Direction marks steer mixed left-to-right and right-to-left text.
- Hold a gap. Some apps collapse blank lines or repeated spaces, so a blank-looking character on its own line can keep a gap open.
- Fill a required field in test data. Developers and testers use these characters on purpose to see how a form, a database or a search handles input that looks empty.
- Carry data in a hidden form. Tag characters and runs of zero-width characters can encode text that nobody sees. That is a reason to clean text you get from sources you do not trust.
What invisible text cannot do
- It is not private. Anyone can select it, search it, copy it or run it through a checker. A screen reader may announce it or skip it unpredictably.
- It is not reliable. Apps trim, filter or replace these characters, and fonts draw some of them as empty boxes. A trick that works in one chat app can fail in the next.
- It does not stay free. The characters still count toward length limits, and they break exact matches in spreadsheets and databases.
- It does not help search rankings. Google's spam policies list hidden text and links as a violation. Stuffing a web page with white-on-white keywords is a bad idea.
Mail filters and moderation systems can also treat padding made of hidden characters as a warning sign, so using it in messages is more likely to hurt than help.
Hidden characters in text you copy
Most invisible text is not put there on purpose. It arrives with copy and paste from web pages, chat tools, PDFs and exports. The zero-width space is the usual suspect, and the no-break space is next. Because the tag-character block can hold a full invisible copy of English text, it is wise to clean anything you paste into a document, a form or a chat box from a source you cannot vouch for. Researchers have shown that some AI chat systems can read tag characters that a person cannot see.
How to remove invisible text
| What you have | How to remove it |
|---|---|
| Zero-width space, word joiner, byte order mark, soft hyphen, direction marks, tag characters, control codes | Switch on Remove invisible characters in the AI Text Cleaner. Tag characters inside subdivision flag emoji such as the flag of Scotland are kept so the flag still displays. |
| No-break space, em space, thin space and other special spaces | Switch on Replace unusual spaces. They become ordinary spaces. See Unicode space characters. |
| Zero-width joiner and non-joiner | The cleaner deletes them unless they sit between two emoji. If the text is Persian or Hindi, read the guide to the zero-width non-joiner first. |
Hangul filler U+3164 and braille pattern blank U+2800 | The cleaner leaves these alone. Use a replacement of your own, such as the code below. |
| Text hidden by formatting | Paste as plain text, or change the formatting. In Word, select all and open the Font dialog (Ctrl + D on Windows), then untick Hidden. See how to paste without formatting. |
To remove the Hangul fillers and the braille blank in Python:
import re
text = re.sub("[\u3164\uffa0\u115f\u1160\u2800]", "", text)
In JavaScript the same pattern is text.replace(/[\u3164\uffa0\u115f\u1160\u2800]/g, "").
Common mistakes
- Relying on trim. A trim function removes white space, which is a short list. The zero-width space, the Hangul filler and the braille blank are not on it. For the full picture see whitespace characters.
- Treating a blank-looking cell as empty. A spreadsheet cell holding one invisible character is not blank. A test for an empty cell passes it as full, and a text length count says 1. More on this in the guide to the blank character.
- Forgetting document-level hidden text. A Word file can carry hidden text, comments and other content you never see in print. Before sending a document outside your team, use File > Info > Check for Issues > Inspect Document.
- Trusting a screenshot. A picture of text shows only what is visible. The pasted text can still contain more.
Quick answers
Is invisible text the same as a space? No. A space is one specific character, U+0020. Invisible characters have other codes, so software does not treat them as spaces.
Can invisible text be copied? Yes. It is real text. Select the area, copy, and paste it into a checker to see the codes.
Why is my text longer than it looks? Hidden characters count toward the length. A character count in the cleaner's summary shows the number before and after cleaning.
Do I need to worry about the Hangul filler? Only if it is showing up where it should not. Our short guide to the Hangul filler explains what it is.