Inspect and Remove Zero-Width Characters Safely

TextRuns in Your Browser (No Uploads)

Inspect decoded text for six named zero-width Unicode controls, review code-point and line positions, and remove only the types you approve.

What to do next

Continue with a related workflow or open the next tool that usually follows this task.

How to Use This Tool

Keep an untouched source, then paste or upload decoded text up to 1 MiB of UTF-8.

Choose Inspect only to map controls without edits, or Common cleanup for U+200B and U+FEFF.

Use Choose types when one confirmed control must be removed; select All supported only after reviewing shaping and line-break risks.

Run the inspection and compare detected, removed, preserved, affected-line, and per-code-point counts.

Review the first reported positions and visible context against the source, especially ZWJ, ZWNJ, WORD JOINER, MVS, and leading U+FEFF.

Copy or download the exact output, then test identifiers, search keys, links, code, or multilingual text in its destination before replacing the source.

When to Use This Tool

Identity and search mismatch review

Find an invisible separator that makes two visually identical email addresses, usernames, database keys, or search terms compare differently.

Code and structured-data cleanup

Inspect pasted source, CSV fields, environment values, and identifiers for supported controls before a parser or validator consumes them.

Multilingual and emoji inspection

Preserve ZWJ and ZWNJ by default while checking whether an emoji sequence or Arabic, Persian, or Indic text contains intentional joining controls.

Line-break and copy-paste diagnosis

Locate U+200B, WORD JOINER, or legacy U+FEFF when copied text wraps or searches differently from what its visible spacing suggests.

Obfuscation triage with evidence

Record code-point positions in a suspicious string for human review without treating a hidden control as proof of malicious behavior.

Common Mistakes

Removing every detected control by default

ZWJ and ZWNJ can form emoji or control cursive and Indic shaping; WORD JOINER and ZERO WIDTH SPACE affect line breaking. Start with Inspect only or Common cleanup, then compare every protected type with the source before selecting All supported.

Assuming every invisible Unicode character is covered

This tool intentionally recognizes six code points. Soft hyphen, bidirectional marks, variation selectors, combining marks, ordinary whitespace, and every other default-ignorable character are outside its contract and need a separate review.

Treating decoded U+FEFF as complete BOM evidence

A leading U+FEFF in an already decoded browser string may be BOM residue or text. The original UTF-8, UTF-16, or UTF-32 signature bytes are no longer available here, so use a byte-aware file workflow when encoding evidence matters.

Combining removal with unrelated normalization

Unicode normalization, line-ending conversion, trimming, or editor auto-formatting can create additional changes. Run those steps separately and compare the zero-width result first so each change has a clear cause.

Using detection as a security verdict

Hidden controls can explain mismatches or obfuscation, but their presence does not prove malicious intent and their absence does not make content safe. Validate identifiers, links, and source code with the destination system and its security controls.

Examples

Clean common hidden separators without splitting emoji

Common cleanup removes U+200B and U+FEFF while preserving the ZWJ that keeps the technologist emoji sequence together. CRLF separators remain exact.

Input
account​@example.com
Emoji: 👩‍💻
legacymark
Output
account@example.com
Emoji: 👩‍💻
legacymark

Remove all six supported controls after review

All supported is intentionally destructive: it removes ZWSP, ZWNJ, ZWJ, WORD JOINER, U+FEFF, and MVS only after that broader policy is selected.

Input
a​b‌c‍d⁠ef᠎g
Output
abcdefg

A bounded Unicode inspection and selective-removal contract

The detector has a fixed six-code-point contract: U+200B, U+200C, U+200D, U+2060, U+FEFF, and U+180E. It does not use a broad invisible-character regular expression, so soft hyphen, bidirectional controls, variation selectors, combining marks, and other default-ignorable code points are not silently removed.

Inspect only selects no characters. Common cleanup selects U+200B and U+FEFF. All supported selects all six. Choose types applies the exact checked set in a deterministic definition order; duplicate selections cannot cause duplicate removal.

ZWSP provides a line-break opportunity, WORD JOINER and legacy U+FEFF can prohibit breaks, ZWNJ and ZWJ affect joining in complex scripts, ZWJ participates in emoji sequences, and MVS is Mongolian-specific. These semantics make broad deletion a potentially meaning-changing operation.

Positions use zero-based internal code-point and UTF-16 offsets, displayed as a one-based code-point position plus one-based line and column. CRLF counts as one line boundary, astral characters count as one code point, and visible context escapes tabs, line endings, and adjacent supported controls.

Input is rejected rather than truncated when it is empty, contains an unmatched UTF-16 surrogate, or exceeds 1,048,576 UTF-8 bytes. All occurrences contribute to totals; at most 200 detailed records are retained by the engine and the interface displays the first 25 to keep the page responsive.

Output is built by omitting selected code points only. The engine does not trim, normalize, change line endings, reinterpret encoding bytes, or contact a server. U+FEFF is inspected in decoded text; byte-level BOM identification belongs to a separate file-encoding workflow.

Frequently Asked Questions

Which characters are detected?

It recognizes U+200B ZERO WIDTH SPACE, U+200C ZERO WIDTH NON-JOINER, U+200D ZERO WIDTH JOINER, U+2060 WORD JOINER, U+FEFF ZERO WIDTH NO-BREAK SPACE, and U+180E MONGOLIAN VOWEL SEPARATOR. It does not claim to enumerate every invisible or default-ignorable Unicode character.

What does Common cleanup protect?

Common cleanup removes U+200B and U+FEFF. It preserves ZWNJ, ZWJ, WORD JOINER, and MVS because those controls can alter joining, emoji presentation, line breaks, or script behavior. Inspect only changes nothing, and Choose types gives explicit control.

Why can removing ZWJ change an emoji?

U+200D can connect emoji components into one displayed sequence and also affects complex-script joining. Removing it can turn one visible emoji into several symbols or change text shaping, which is why it is not selected in Common cleanup.

Does cleanup normalize text or line endings?

No. Characters that are not selected remain byte-for-byte within the decoded JavaScript string. LF, CRLF, CR, tabs, spacing, normalization form, and a terminal line ending are not rewritten by the removal engine.

Can this verify and repair a file BOM?

Not completely. The tool can report a leading U+FEFF code point in decoded text, but it cannot recover the source file's original encoding signature bytes. A byte-aware BOM tool is the right workflow for UTF-8, UTF-16, or UTF-32 file signatures.

Does finding a zero-width character prove an attack?

No. Position evidence helps investigate a mismatch, suspicious identifier, or obfuscated string, but context determines intent. Review the untouched source and validate the cleaned value in the system that will consume it.

Is pasted text sent to a server?

Inspection, removal, file reading, copying, and download generation run locally in the browser and the tool does not send input to a conversion service. Browser extensions, device policy, and the destination where you paste the result remain outside that boundary.

How This Tool Was Verified

Maintained and tested by Reviewed

Method: Verification started with the guide's “Remove common separators while retaining an emoji joiner” fixture in Inspect and Remove Zero-Width Characters Safely. The run followed “Preserve the exact source and provenance” through “Classify each control by its possible effect”, compared the produced result to the documented expectation, and checked the distinct limits behind “Replacing the source before reviewing positions” and “Deleting ZWJ or ZWNJ as harmless whitespace”.

Expected result: The ordinary zero-width separators were removed from the address and legacy text, while the ZWJ inside 👩‍💻 remained so the emoji sequence did not split.

Open the tested workflow

Related workflow guides

Use these focused guides when you need a practical workflow before opening the tool.

Workflow guide

Audit text metrics before publishing or comparing drafts

Use this workflow when an editor, researcher, support team, or SEO review asks whether a draft repeats words, contains a target phrase too often, reads easily, sounds negative, or resembles another version. It records the unit, language, normalization, denominator, limits, and interpretation before analysis, then separates deterministic evidence from editorial judgment.

Workflow guide

Prepare reproducible text fixtures and decorative samples safely

Use this workflow when a test, mockup, terminal demo, documentation example, or harmless visual experiment needs generated or rearranged text. It separates structural operations from decoration, preserves source and separator behavior, records every seed and limit, and requires a plain-text alternative whenever FIGlet, mirror, upside-down, Braille-subset, or Zalgo output may not survive fonts, assistive technology, search, or copying.

Workflow guide

Normalize Unicode before comparing text across systems

A reliable Unicode-normalization workflow preserves the original representation, confirms the target system's contract, distinguishes canonical normalization from compatibility folding, inspects exact code points and hidden characters, compares the result, and validates the completed value where it will be stored or matched.

Workflow guide

Verify text limits across Unicode counting units

A reliable text-limit check starts from the destination contract, preserves the source representation, measures several Unicode units, includes normalization and invisible-character fixtures, exercises the limit on both sides, and verifies the value after storage or transmission.

Workflow guide

Inspect zero-width characters before removing them from text

Use this workflow when two values look identical but compare, search, wrap, parse, or render differently. Map supported controls before editing, distinguish common hidden separators from joining and line-break controls, retain exact line endings and normalization, and record why each removal was safe.

Related Tools

Continue with another maintained workflow

Browse All Tools