Text Cleaner
Sanitize text copied from the web, documents or AI chats: invisible characters, curly quotes, odd spaces and Unicode quirks, each step under your control.
Processed locally in your browser/ Your data stays in your browser.
What is Text Cleaner?
Text copied from word processors, web pages and chat apps hides characters you cannot see: zero-width spaces, soft hyphens, byte-order marks, control characters, non-breaking spaces and curly quotes. They break searches, comparisons, code, URLs and databases in confusing ways.
The Text Cleaner lets you switch on exactly the fixes you need: Unicode normalization (NFC, NFKC, NFD, NFKD), removing zero-width characters and controls, replacing special spaces, straightening quotes and dashes, stripping accents, removing emoji, collapsing whitespace and trimming. Joiners and direction marks are separate and off by default because they matter in Arabic, Persian and emoji. A report lists how many characters each step changed.
How does it work?
- Paste the text you want to clean.
- Tick the fixes you need; the defaults handle invisible characters, control characters, special spaces, smart quotes, extra whitespace and the trim.
- Read the change report in the notes to see what was fixed, then copy the cleaned text.
Common use cases
- Preparing text copied from a chat or document for code, JSON, YAML or CSV.
- Finding why two identical-looking strings do not match (hidden characters).
- Turning "smart" punctuation into plain ASCII for plain-text systems.
- Stripping accents to make search keys, file names or URL slugs.
Examples
Try this input in the tool above:
“Café” — it’s a test 😀 with gaps
"Café" - it's a test 😀 with gaps
Privacy
Text Cleaner runs entirely in your browser. The text or files you provide are processed on your device and are not uploaded, logged or stored on our servers.
Limitations
Stripping accents and NFKC normalization are lossy (for example fi becomes fi, ² becomes 2). Removing joiners can damage Arabic, Persian, Indic scripts and emoji sequences, so leave that option off unless you need it.
Frequently asked questions
What are zero-width characters?
Invisible characters such as the zero-width space (U+200B), word joiner (U+2060), BOM (U+FEFF) and soft hyphen (U+00AD). They take no visible space but count as characters.
Which normalization should I choose?
NFC (the default) composes accents into single characters and is safe for almost everything. NFKC also folds compatibility characters (ligatures, full-width letters), which is useful for matching but changes appearance.
Does it remove emoji safely?
Yes. Emoji, skin tones, flags and joined sequences are removed as a whole, while symbols like © and ™ are kept.
Related tools
Remove Extra Spaces
Clean up spacing in pasted text: double spaces, stray tabs, trailing spaces and runs of blank lines.
Text Tools
Unicode Character Inspector
Paste text or an emoji and see exactly which code points, bytes and scripts it is made of.
Encoding & Decoding
Case Converter
One tool for every text case: pick a style from the list and the text is converted instantly.
Text Tools
Trim Lines
Remove the spaces and tabs at the start and end of each line of a list or block of text.
Text Tools
HTML Entities Decoder
Turn <, é, € and 😀 back into the characters they stand for.
Encoding & Decoding
Strip HTML Tags
Delete every tag from a piece of HTML and keep only the text, with your choice of line breaks and entity decoding.
Developer Tools
Unicode Escape Converter
Turn é, ☕ and 😀 into \u00E9, \u2615 and \uD83D\uDE00 (or another escape style) for source code, JSON or CSS.
Encoding & Decoding