1. Home
  2. Text
  3. Remove Line Breaks

Remove Line Breaks

Join broken lines from PDFs and emails while keeping paragraphs.

Runs in your browser · No upload Works offline
Blank lines between paragraphs stay; single line breaks inside a paragraph become spaces. Ideal for text copied from PDFs.
Result
When you copy text from a PDF, every line often ends with a hard line break, and long words get hyphenated across lines. This tool joins those lines back into paragraphs while keeping the blank lines between them.
Lines before
6
Lines after
3
Breaks removed
3
Characters
214

How to use

  1. Paste text with unwanted line breaks — typically copied from a PDF, an email, a terminal or a subtitle file.
  2. Choose a mode. Keep paragraphs is the right choice most of the time.
  3. 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-⏎ple back into example. 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, so COVID-⏎19 is left alone.

Things to know

  • Hyphen rejoining cannot tell a line-end split from a real compound word: well-⏎known becomes wellknown. 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.

Coming soon

Can't find the tool you need?

Tell us what you want to do. We build the most requested tools first.