How to use
- Paste text with unwanted line breaks — typically copied from a PDF, an email, a terminal or a subtitle file.
- Choose a mode. Keep paragraphs is the right choice most of the time.
- Copy the result or save it with Download .txt.
Modes compared
For the input first line⏎second line⏎⏎new paragraph (⏎ = line break):
| Mode | Result | Use it when |
|---|---|---|
| Keep paragraphs | first line second line, a blank line, then new paragraph |
Restoring paragraphs in text copied from a PDF or email |
| Replace with spaces | first line second line new paragraph |
You need everything on a single line, e.g. for a form field or spreadsheet cell |
| Remove completely | first linesecond linenew paragraph |
Nothing may be inserted at the break, e.g. a long ID or key split across lines |
Options
- Collapse multiple spaces turns runs of spaces and tabs into a single space and trims each line, which also cleans up the indentation PDFs often add at line starts.
- Rejoin hyphenated words (English) turns
exam-⏎pleback intoexample. It only applies when a letter is followed by a hyphen at the end of a line and the next line starts with a lowercase letter, soCOVID-⏎19is left alone.
Things to know
- Hyphen rejoining cannot tell a line-end split from a real compound word:
well-⏎knownbecomeswellknown. Turn the option off for text full of hyphenated compounds. - Lines are joined with a space, which is right for English, Korean and other languages that separate words with spaces. For Chinese or Japanese text, use Remove completely instead.
- Windows (CRLF), classic Mac (CR) and Unix (LF) line endings are recognized. Line breaks at the very start and end of the text are dropped.
FAQ
Why does text copied from a PDF have line breaks everywhere?
PDFs typically store text as positioned lines rather than flowing paragraphs, so copying keeps a hard break at the end of every visual line.
Can I check the word or character count afterwards?
The result’s character count is shown below it. For words, bytes and characters without spaces, use the character counter.
Can I see exactly what changed?
Paste the original and the cleaned text into text diff to compare them.