Text Cleaner
Paste text from a PDF, email or web page and switch on the fixes you need: collapse extra spaces, join broken PDF line breaks while keeping real paragraphs, straighten smart quotes, strip invisible characters or remove HTML tags. The preview updates as you toggle each one. Your text is never uploaded.
Updated
How to use the Text Cleaner
- 1Paste your messy text.
- 2Switch on the fixes you need; each one is independent.
- 3Watch the preview update as you toggle them.
- 4Copy the cleaned result.
How it works
Text copied from a PDF or an email arrives with problems that are invisible until they cause trouble. Non-breaking spaces look identical to ordinary spaces but break search and word wrap. Zero-width characters have no appearance at all yet corrupt string comparisons. Smart quotes and em dashes break code and some data imports.
Line breaks are the most common problem with PDF text. A PDF breaks lines to fit the page, not to end paragraphs, so pasted text arrives with a break after every visual line. The line-joining option merges those back into flowing paragraphs while keeping genuine paragraph breaks — it treats a blank line as a real break and a single break as an artefact.
HTML stripping removes tags and decodes entities, turning copied web markup back into plain text. It operates on the text as data and never renders it, so pasting hostile markup here cannot do anything.
Your text is processed by JavaScript running in this page and is never sent over the network. That matters when you are pasting a draft, a client brief, meeting notes or anything else you would rather not hand to a server.
Tips and common mistakes
- Turn on line joining for text copied out of a PDF, so each paragraph flows again.
- Straighten smart quotes before pasting text into code, a CSV file or a data import.
- Remove invisible characters when two pieces of text that look identical will not match.
- Switch on only the fixes you need and check the preview after each one.
Frequently asked questions
Why does my PDF text have a line break after every line?
What are invisible characters and why remove them?
What are smart quotes?
Is it safe to paste HTML here?
How do I remove extra spaces?
Can I turn HTML into plain text?
Is my text uploaded?
Guides
- How many characters fit in a text message?
- How to turn a voice message into text — privately
- How long does it take to read or say 1,000 words?
- Title case rules: which words to capitalise in a headline
- How to remove duplicate lines from a list
- How to fix text copied from a PDF: broken lines, odd spaces and quotes
- How to format a LinkedIn post: bold text, spacing and the “see more” cut
- How to check an email address is valid before you send
- How to fix text typed with caps lock on
- How to remove line breaks from text
- How to convert curly quotes to straight quotes
- Instagram caption and bio character limits
- How to find and remove invisible characters in text
- Why text shows ’, é or � instead of apostrophes and accents
- Why a CSV file opens in one column in Excel — and how to fix it
- Why Word, Google Docs and online counters give different word counts
- Why two texts look identical but a comparison says they differ