Use this free text cleaner to fix messy text in seconds. Paste text copied from a web page, a PDF, an email, or a chat, and the tool removes extra spaces, stray blank lines, invisible characters, HTML tags, and curly quotes. Pick one of three presets, or change each option yourself. You can copy the clean text, download it as a text file, or send it back to the input to clean it again. Everything runs in your browser and the result updates as you type.

The cleaner changes spacing, hidden characters, and formatting clutter, not your words. The only exception is the accent option, which you choose yourself.

How to use the text cleaner

Paste your text and the cleaned version appears instantly.

  • Paste your text: add the messy text you want to tidy.
  • Choose a preset: pick Basic, Web paste, or Strict.
  • Adjust the options (optional): turn each cleaning step on or off, such as spaces, blank lines, quotes, HTML tags, or accents.
  • Copy or download: copy the result, download it as a .txt file, or use Use as input to clean the result again.

What each preset does

PresetBest forWhat it does
BasicEveryday tidyingTrims lines, collapses repeated spaces, collapses blank lines to one, and removes invisible characters.
Web pasteText from websites and documentsDoes everything in Basic, then converts smart quotes, long dashes, and ellipsis to plain characters and removes HTML tags.
StrictThe simplest plain textDoes everything in Web paste, then removes all blank lines and strips accents.

What each option fixes

OptionExampleWhat it does
Trim lines" Hello " → "Hello"Removes spaces at the start and end of every line.
Collapse spacesa b → a bTurns repeated spaces, tabs, and non-breaking spaces into one space.
Blank lines3 empty lines → 1Keeps them, collapses each run to one blank line, or removes them all.
Invisible characterszero-width space → nothingDeletes zero-width characters, soft hyphens, byte order marks, and control characters.
Smart quotes“Hi” — ok… → "Hi" - ok...Converts curly quotes, long dashes, and the ellipsis character to plain ones.
HTML tags<p>Hi</p> → HiRemoves tags and turns line-ending tags such as <br> and </p> into line breaks.
Accentscafé → cafeStrips accent marks, or removes every non-English character.

What this tool does and does not do

This tool cleans formatting clutter in plain text. It does not check spelling or grammar, rewrite your sentences, or fix the meaning of anything. It treats your text as plain text, so bold, italics, and other rich formatting are not kept, and removing HTML tags is a simple cleanup rather than a full HTML parser. The option to remove all non-English characters also removes symbols such as € and emoji, so use it only when you need plain English letters. For one job only, you can also use Remove Extra Spaces or Remove Line Breaks.

Clean text copied from the web before you paste it into code, a spreadsheet, or a database. Hidden characters and curly quotes cause errors that are hard to spot.

Worked examples

Cleaning text copied from a web page

Paste text full of curly quotes, double spaces, and leftover tags, then choose Web paste. The quotes become plain, the extra spaces collapse, the tags disappear, and the result is ready to paste anywhere.

Removing hidden characters

Text copied from chat apps and PDFs often hides zero-width characters that break searches or comparisons. Any preset removes them, and the summary tells you how many were found.

Making the simplest plain text

Choose Strict to remove every blank line and strip accents. "Café menu" on one line and "Crème brûlée" on the next become "Cafe menu" and "Creme brulee" with nothing between them.

Common text cleaning mistakes

  • Removing all non-English characters by accident. That option also deletes symbols, currency signs, and emoji, so strip accents instead when you only want plain letters.
  • Removing blank lines from text that needs paragraphs. Use Collapse to one blank line to keep paragraph breaks.
  • Stripping HTML you meant to keep. If the text is real HTML code, turn the HTML option off.
  • Leaving hidden characters in. They look like normal text but can break matching, imports, and file names.

Frequently asked questions

What does a text cleaner do?

A text cleaner removes the clutter that builds up in pasted text, such as extra spaces, empty lines, hidden characters, HTML tags, and curly quotes, so the text is tidy and consistent.

How do I clean text?

Paste your text into the tool, pick a preset such as Basic, Web paste, or Strict, and copy the cleaned result. You can also change each option yourself.

What are invisible characters?

Invisible characters are characters that take up no visible space, such as zero-width spaces, soft hyphens, and byte order marks. They often arrive when you copy text from web pages, PDFs, or chat apps, and they can break searches, code, and spreadsheets.

Why convert smart quotes to plain quotes?

Curly quotes, long dashes, and the single ellipsis character often cause errors in code, spreadsheets, and databases. Converting them to plain straight quotes, hyphens, and three dots makes the text safe to use anywhere.

Will the tool change my words?

No. It only changes spacing, hidden characters, tags, and punctuation styles. The one exception is the accent option, which turns letters such as é into e when you choose to strip accents.

What is the difference between the three presets?

Basic tidies spacing and hidden characters. Web paste adds plain quotes and HTML tag removal for text copied from websites. Strict also removes every blank line and strips accents for the simplest possible plain text.

Where does my text go?

The cleaning runs in your browser. This page does not send or save the text you paste, and clearing the form removes it from the screen.

Is there a limit on text length?

The tool accepts up to 100,000 characters of text. For longer content, clean it one section at a time.

Share this article