Free Remove Line Breaks Tool Online

Free online tool to remove line breaks from text copied from PDFs or emails. Keep paragraphs, rejoin hyphenated words, or replace breaks with a space or comma.

  • No upload, 100% private
  • Instant, in your browser
  • 100% free, no signup
Loading tool…
Read the complete guideHow to Fix Broken Line Breaks in Text Copied From a PDF or Email →

About the Remove Line Breaks tool

Copy a paragraph out of a PDF, an old email or a terminal window and you usually get hard line breaks in the middle of every sentence. Paste that into a document, a web form or a social post and it looks ragged, with lines stopping halfway across the page. Fixing it by hand means deleting dozens of breaks one at a time and hoping you did not merge two paragraphs by accident.

This tool removes line breaks for you as you paste. By default it keeps real paragraphs: a blank line is treated as a paragraph boundary and preserved, while single breaks inside a paragraph are joined. Each removed break can become a space, nothing at all, a comma or any custom text you type, which also makes the tool handy for turning a column of values into one line.

PDF text often splits words across lines with a hyphen, as in “inform-” and “ation”. With Join hyphenated words switched on, a hyphen at the end of a line followed by a lowercase letter is removed and the word is rejoined. Tidy spaces trims each line and collapses double spaces left behind. Everything runs locally in your browser, so confidential documents never leave your device.

How to use Remove Line Breaks

  1. Paste your text into the “Text with line breaks” box, or click “Sample” to try an example.
  2. Choose what each break becomes in “Replace each line break with”: a space, nothing, a comma or custom text.
  3. Leave “Keep paragraphs” on to preserve blank-line paragraph breaks, or turn it off to make everything one block.
  4. Toggle “Join hyphenated words” and “Tidy spaces” to clean up text copied from PDFs.
  5. Copy the cleaned text with “Copy” or save it with “Download”.

Features

Paragraph-aware

Blank lines are kept as paragraph breaks while single breaks inside a paragraph are joined.

Flexible replacement

Replace breaks with a space, nothing, a comma, comma plus space, or your own text including \t.

Hyphenation repair

Rejoins words that a PDF split across two lines with a trailing hyphen.

Live count

Shows how many line breaks were removed and how many remain as you type.

Works offline, stays private

All processing happens in your browser with no upload.

When to use it

  • Clean up a quote copied from a PDF report before pasting it into a presentation.
  • Fix email text that was hard-wrapped at 72 characters so it reflows on mobile.
  • Turn a vertical list of tags into a single comma-separated line.
  • Prepare subtitles or OCR output for translation software that expects full sentences.
  • Join log lines into one string for a search query or bug report.

Frequently asked questions

How do I remove line breaks but keep paragraphs?

Leave “Keep paragraphs” switched on. Any blank line in your text is treated as the end of a paragraph and kept, while the single breaks inside each paragraph are replaced.

Why does text copied from a PDF have line breaks?

PDF files store text as positioned lines rather than flowing paragraphs, so copying gives you a break at the end of every visual line. This tool rejoins those lines.

Can I replace line breaks with a comma?

Yes. Choose “Comma” or “Comma + space” in the replacement menu, or pick “Custom text…” and type any separator such as a semicolon or pipe.

Will it merge words that were split with a hyphen?

With “Join hyphenated words” on, a hyphen at the end of a line is removed when the next line starts with a lowercase letter. Real compound words that happen to end a line, such as “well-” + “known”, would also be joined, so check the result.

Does it handle Windows and Mac line endings?

Yes. CRLF (Windows), LF (macOS, Linux) and old CR line endings are all recognised.

Related tools