Remove Line Breaks

Clean up text copied from PDFs, emails, or scanned documents by removing stray line breaks while keeping your paragraphs intact.

  • Free
  • No signup
  • Private

Overview

Clean up text copied from PDFs, emails, or scanned documents by removing stray line breaks while keeping your paragraphs intact.

Benefits

  • Fixes text broken by PDF or email line wraps
  • Choice of replace-with-space or full removal
  • Keeps paragraph breaks separate from line breaks
  • Runs entirely in your browser

Use Cases

  • Cleaning PDF-copied text before editing
  • Fixing email-quoted paragraphs
  • Preparing scraped text for publishing
  • Tidying up OCR output

Users Also Use

How to Use

  1. Paste text that has unwanted line breaks.
  2. Choose to replace breaks with a space or remove them entirely.
  3. Copy the cleaned, single-block text.

Why text ends up with unwanted line breaks

Text copied from PDFs, emails, terminal output and some websites often has a hard line break at the end of every visual line. Pasted into a document, a form or a social post, it shows up as short broken lines instead of flowing paragraphs. This tool removes those breaks in one step. It handles both Windows (CRLF) and Mac/Linux (LF) line endings.

The two modes

  • Replace with space (default): each line break becomes a space, any run of spaces or tabs is reduced to one space, and spaces at the start and end are removed. Use this for normal prose so words on either side of a break do not stick together.
  • Remove completely: line breaks are deleted and nothing is put in their place. Use this for data that was wrapped mid-value, such as a long URL, a Base64 string or an API key split across lines.

Worked example

Input copied from a PDF:

Remove line breaks from text
copied out of PDF files
in one click.

Replace with space:
Remove line breaks from text copied out of PDF files in one click.

Remove completely:
Remove line breaks from textcopied out of PDF filesin one click.

Keeping paragraphs

Both modes join everything into a single block, including the empty lines between paragraphs. If you want to keep paragraphs, run the tool on one paragraph at a time, or paste the result back into your editor and press Enter where each paragraph should start.

Other uses

  • Turning a vertical list into one line before adding it to a spreadsheet cell or a search box
  • Cleaning up text pasted from a chat or terminal before posting it
  • Joining a wrapped command, URL or key back into one line

If you need the list items separated by commas instead of spaces, use the Comma Separator. All processing runs in your browser and the text is not uploaded.

FAQ

Does it remove all whitespace?
No, only line breaks and the extra spaces they create. Normal word spacing is preserved.
Why does pasted PDF text have broken lines?
PDF and email text often carries a hard line break at the end of every visual line. This tool joins those lines back into normal paragraphs.
Can I keep paragraph breaks but remove single line breaks?
Yes. Choose the option to replace single breaks with a space while double breaks (paragraphs) are left intact.
Will removing line breaks also remove double spaces?
In Replace with space mode, yes: any run of spaces, tabs and line breaks becomes a single space. In Remove completely mode, existing spaces are left as they are.
Does it work with Windows line endings?
Yes. Both CRLF (Windows) and LF (macOS, Linux) line breaks are removed.
How do I keep paragraph breaks?
The tool joins all lines, including blank ones. Process each paragraph separately, or add the paragraph breaks back afterwards.

Keep exploring