Unicode safe-removal guide
How to remove zero-width characters safely
You can remove an unwanted zero-width space, but removing every invisible character is not safe. Some join emoji or control how a language is written. Inspect the character and its context first, then select only what you intend to remove. InvisiChar lets you review changes before copying the cleaned text.
Six contexts that need different decisions
| Context | Escaped form | Why removal can matter | Safe default |
|---|---|---|---|
Unwanted zero-width space between A and B: AB | A\u200BB | Removing this U+200B produces AB. In some writing systems, a zero-width space marks a useful word or line-break opportunity. | Prose and Code & data suggest removal; International text asks for review. Keep it if the boundary is intentional. |
| Family emoji 👩👩👧👦 | 👩\u200D👩\u200D👧\u200D👦 | U+200D joins emoji elements into one emoji sequence; removing it can expose separate emoji. | Keep as one atomic finding unless the user explicitly wants the fallback sequence. |
| Persian میروم | می\u200Cروم | U+200C can intentionally prevent joining and carry a distinction relevant to the written text. | Keep in international text; review rather than blindly delete elsewhere. |
| Emoji presentation ✈️ | ✈\uFE0F | U+FE0F requests emoji presentation. Removing it may change appearance to text style. | Protect the variation sequence by default. |
| Bidi controls | abc\u202Etxt\u202C | Controls affect visual ordering while the stored code points remain in logical order. They can be legitimate or confusing. | Show pairs and context; review before removal. |
| Emoji tag sequence | 🏴 + U+E0067…U+E007F | Tag characters can be part of a defined emoji tag sequence and belong to the same grapheme cluster. | Keep the sequence atomic; never delete just one member by default. |
What the InvisiChar presets do
Presets initialize choices for review. They do not edit text automatically, and a detected character is not automatically a deletion recommendation.
| Finding | Prose | Code & data | International text |
|---|---|---|---|
| Standalone zero-width space | Suggested removal | Suggested removal | Review |
| Emoji ZWJ sequence | Protected | Review | Protected |
| ZWNJ in text | Protected | Review | Protected |
| Variation sequence | Protected | Review | Protected |
| Bidi embedding or override | Review | Suggested removal | Review |
| Valid IVC1 frame | Protected | Suggested removal | Protected |
A safer cleanup workflow
- Paste text into InvisiChar Inspect and run an explicit scan.
- Read the risk, legitimate use, position, context, and preset reason for each finding.
- Move to Clean and review category or exact-occurrence choices. Semantic sequences remain atomic.
- Apply selected ranges, inspect the diff, and use Undo if the result is not what you intended.
Limits
InvisiChar has a fixed V1 registry; it is not a complete Unicode database or language engine. Context rules reduce obvious damage but cannot infer every author’s intent. It does not normalize text, replace confusables, repair code, parse JSON, or prove that a character came from a specific application.
If the text came from ChatGPT, Claude, Claude Code, Gemini, Copilot, Grok, or another AI tool, use the AI text hidden-character checker for the same local inspection and review workflow.
Primary sources
- Unicode Technical Standard #51: Unicode Emoji, Version 17.0
- Unicode Standard Annex #9: Unicode Bidirectional Algorithm
- The Unicode Standard 17.0, Chapter 23: Special Areas and Format Characters
Last reviewed: 2026-09-01