How to use Remove Line Breaks
Remove unwanted line breaks from copied text, pasted emails, or exported documents entirely in your browser — no data is sent to any server. Whether you're cleaning up text pasted from a PDF, an email client, or a word processor, this tool strips or replaces line breaks in one click. You can remove all breaks, preserve paragraph spacing, or replace each break with a space for seamless inline text.
- Paste your text — with line breaks — into the input area.
- Choose a mode: "Remove all line breaks", "Keep paragraph breaks" (blank-line-separated blocks), or "Replace with space".
- Optionally enable "Collapse multiple spaces" to clean up double-spaces left after removal.
- Click "Remove Line Breaks" and the cleaned text appears instantly.
- Copy the output or download it as a plain text file.
Your data never leaves your device — 100% private processing.
Line ending types: LF, CRLF, and CR
Three different byte sequences signal a new line across operating systems. Unix, Linux, and modern macOS use a single Line Feed character (LF, \n, hex 0x0A). Windows uses a Carriage Return followed by Line Feed (CRLF, \r\n, hex 0x0D 0x0A). Classic Mac OS — before OS X — used a standalone Carriage Return (CR, \r, hex 0x0D). When text is copied across platforms or exported from applications that do not normalise line endings, documents often contain a mix of all three variants. This tool detects and removes all three regardless of origin.
| Name | Escape | Hex bytes | Platform |
|---|---|---|---|
| LF | \n | 0x0A | Unix, Linux, macOS (OS X+) |
| CRLF | \r\n | 0x0D 0x0A | Windows, DOS, HTTP headers, SMTP |
| CR | \r | 0x0D | Classic Mac OS (pre-OS X) |
Common sources of unwanted line breaks
PDF text extraction inserts a line break at the end of every visible text line, breaking sentences mid-word when the PDF was created from a reflowed document. Email clients hard-wrap long lines at 72 or 76 characters per RFC 2822, leaving short broken fragments when a message is forwarded or copied into a plain text field. Word processors may export RTF or HTML with forced line breaks that survive copy-paste as raw newline characters. Removing these breaks and re-pasting into the target application ensures the text reflows correctly according to the destination container's width.
Worked examples
Join wrapped lines
Inputs: "line one" + newline + "line two"
Result: "line one line two" (replace break with space)
Keep paragraphs
Inputs: text with blank-line gaps
Result: wrapped lines joined; blank-line breaks kept
Address to one line
Inputs: 3-line postal address
Result: single comma- or space-joined line
Glossary
- Line Feed (LF)
- A control character (U+000A) that advances the cursor to the next line; the standard line terminator on Unix, Linux, and modern macOS.
- Carriage Return (CR)
- A control character (U+000D) that moves the cursor to the beginning of the current line; used alone as a line terminator in classic Mac OS.
- CRLF
- The two-byte sequence CR + LF (0x0D 0x0A) used as the line terminator in Windows, DOS, and Internet text protocols such as HTTP and SMTP.
- Hard wrap
- The practice of inserting a literal line break at a fixed column width (typically 72–80 characters), common in email and terminal output, as opposed to soft-wrapping at display time.
- Paragraph break
- A double newline (blank line) that separates paragraphs in plain text, as distinct from a single newline that merely wraps a long line within the same paragraph.
Related reading
Frequently Asked Questions
Why use Remove Line Breaks?
- Detects and removes all three line-ending types — LF, CRLF, CR — regardless of which platform produced them
- Preserve-paragraphs mode keeps intentional blank-line breaks while joining hard-wrapped sentence lines
- Replace-with-space mode ensures words from adjacent wrapped lines do not run together after joining
- Collapse-spaces option cleans up double spaces left behind by break removal in a single pass
Common use cases
- Clean up text pasted from a PDF that inserted a hard line break at the end of every print column
- Restore forwarded email body copy that was hard-wrapped at 76 characters by an email client
- Join a reflowed paragraph copied from a mobile app into a single unbroken line for web entry
- Normalise Windows CRLF line endings in a config snippet before pasting into a Unix-only text editor
- Remove mid-sentence breaks from a transcription file to prepare it for NLP text analysis
Get weekly tool tips & updates
New tools, power-user tips, and productivity hacks — delivered free every Friday.
No spam, ever. Unsubscribe with one click.
Related Text Tools
Text Diff Checker
Compare two texts line by line and highlight added, removed, and unchanged content instantly for copy review, QA checks, and revision auditing.
Sort Text Lines
Sort lines of text alphabetically, numerically, or reverse. Case-insensitive option, remove duplicates, and trim whitespace. Free online line sorter.
Remove Duplicate Lines
Remove duplicate lines from text online. Case-sensitive or insensitive matching. Preserves order or sorts alphabetically. Free online tool.
Find and Replace Text
Find and replace text online with support for regex, case sensitivity, and whole word matching. Bulk text replacement tool — free and private.
Word Counter
Count words, characters, sentences, and paragraphs, and estimate reading time. Free, instant, and private — ideal for essays, articles, and posts.
Case Converter
Convert text to camelCase, PascalCase, snake_case, kebab-case, UPPERCASE, lowercase, Title Case, and Sentence case instantly.
Explore all Text Tools.