InputTestHub

Text Cleaner

Cleans pasted text with a switch for every fix — invisible characters, curly quotes, dashes, odd spaces — and previews each change before you copy.

Text Nothing uploaded No sign-up Free, unlimited
Text tool
Paste something on the left to see the result.
In short Cleaning pasted text fixes the damage that copying between applications does, and most of that damage is invisible. Every fix here is a separate switch: removing zero-width and other invisible characters, straightening curly quotes, turning en and em dashes into spaced hyphens, replacing non-breaking, figure and narrow no-break spaces with ordinary ones, writing the ellipsis character as three dots, collapsing repeated and trailing spaces, and — only if you turn it on — joining lines broken in the middle of a paragraph. A preview shows each change with invisible characters named, a table shows how many each switch fixed, and your original always stays in the input box. After using the result as new input you can restore the original, and you can send the before and after to Text Compare to see every change side by side.

How to use the Text Cleaner

  1. Paste your text into the input box.
  2. Turn off any switch for a kind of character you want to keep.
  3. Check the preview: removed characters are struck through, and invisible ones are named in brackets.
  4. Copy the cleaned text, or press “Compare before and after” to see the changes in Text Compare.

About the Text Cleaner

The Text Cleaner removes the characters that copying from Word, PDFs, web pages and chat apps quietly adds, and shows you each change before you use the result.

A switch for every fix

SwitchWhat it changes
Invisible charactersRemoves zero-width space, zero-width non-joiner, zero-width joiner, byte-order mark, soft hyphen, word joiner and Mongolian vowel separator.
Smart quotesCurly single and double quotes become straight ASCII quotes.
DashesEn and em dashes become a hyphen with a space either side.
Non-breaking spacesNon-breaking, figure and narrow no-break spaces become ordinary spaces.
EllipsisThe single ellipsis character becomes three full stops.
Collapse spacesTwo or more spaces or tabs in a row become one space, and spaces at the end of each line go.
Stray line breaksOff by default. Joins lines inside a paragraph while keeping blank lines between paragraphs.

See the changes before you trust them

The preview marks every removed character and every addition, and names the invisible ones — [ZWSP] for a zero-width space, [NBSP] for a non-breaking space — so you can see what was there. A table lists how many characters each switch fixed. Your original text is never overwritten in the input box; if you use the cleaned text as new input, a Restore original button brings the first version back.

Compare before and after

“Compare before and after” opens Text Compare with your original and cleaned text already filled in. The hand-off uses this tab’s session storage only and is deleted as soon as it is read.

Related tools

Where this tool stops

It changes characters, not meaning: it will not fix spelling or grammar, and a curly quote inside a quotation you want to keep typographic will be straightened unless you turn that switch off. Formatting such as bold, links and fonts is already gone once text is pasted as plain text.

Explained in our guides

All guides

Frequently asked questions

Is the Text Cleaner free?
Free, unlimited, and no email address required. You can use it a hundred times a day and nothing changes.
Is my data uploaded anywhere?
No. The Text Cleaner runs entirely in your browser using JavaScript. Nothing is transmitted, logged or stored, which you can verify yourself in the Network tab of your browser's developer tools.
Who is the Text Cleaner for?
The jobs it is built for: cleaning text pasted from Word, Google Docs or a PDF. Removing zero-width characters that break code or CSVs. Preparing copy for a CMS that mangles curly quotes. It is built for exactly those cases rather than being a general-purpose tool with this bolted on.
What are the reference figures here?
Invisible characters removed is Zero-width space, zero-width non-joiner, zero-width joiner, byte-order mark, soft hyphen, word joiner, Mongolian vowel separator. Quotes is Curly single and double quotes become straight ASCII quotes. Dashes is Em dash and en dash become a hyphen surrounded by spaces. These are printed on the page itself, so you do not have to take them on trust.
Can I use the Text Cleaner on mobile?
Yes. The page is responsive and the page works in Chrome, Safari, Firefox, Edge and Samsung Internet on both Android and iOS. There is no app to install and nothing to sign into.

Related text tools

All 92
01

Case Converter

Converts text between twelve cases: UPPER, lower, Title, Sentence, camelCase, PascalCase…

02

Uppercase Converter

Converts any text to UPPERCASE instantly, keeping numbers, punctuation and line breaks exactly…

03

Lowercase Converter

Converts any text to lowercase, including text that was typed with Caps Lock on by mistake.

04

Title Case Converter

Converts headings to proper Title Case using AP and Chicago rules, keeping short words like…

05

Sentence Case Converter

Rewrites text in sentence case: first letter of each sentence capitalised, the rest lowercase…

06

camelCase Converter

Turns any phrase into camelCase for JavaScript, Java and JSON keys, stripping spaces, hyphens…

07

PascalCase Converter

Converts phrases to PascalCase (UpperCamelCase) for class names, React components and type…

08

snake_case Converter

Converts text to snake_case for Python variables, database columns and file names.

09

kebab-case Converter

Converts text to kebab-case for URLs, CSS class names and HTML attributes.

10

CONSTANT_CASE Converter

Converts text to SCREAMING_SNAKE_CASE for environment variables, constants and configuration…