Remove line breaks / new lines from any text
Strip line breaks and new lines from any text. Replace with a space, with nothing, or a custom string. Keep paragraphs intact or flatten everything. Runs in your browser — nothing uploaded.
For text that wrapped where you didn't want it to.
Pasting from a PDF, email body, or log dump usually drags in line breaks that broke the original text at column 72 or 80. This tool stitches it back into flowing prose.
Keep paragraph breaks (double newlines), or flatten everything to one block. Replace single breaks with a space, with nothing, or with a custom separator like | . Runs in your browser — your text never leaves the page.
Paste your text
Drop in any wrapped text — a PDF excerpt, an email body, a log dump, code comments that broke at 80 columns. The tool reads it as-is.
Pick a replacement
Replace line breaks with a single space (default — for flowing prose), with nothing (for slug-style concatenation), or with a custom string like " | " or "; ".
Decide on paragraphs
Toggle Keep Paragraphs to preserve double-newline breaks. Toggle Drop Blanks to remove empty lines entirely. Trim cleans the result.
What's the difference between "Replace with SPACE" and "NONE"?
SPACE inserts a single space where each line break was, so words don't collide. NONE removes the break with no replacement — useful for slugs, hashes, or any string where line breaks were noise.
Why is "Keep Paragraphs" on by default?
Most pasted text has meaningful paragraph breaks (the blank lines between blocks). Stripping those usually breaks readability. Turn it off to fully flatten everything to one block.
Does it handle \r\n (Windows) and \r (old Mac) line breaks?
Yes — all three flavors of newline are treated identically. The output uses \n by default.
Will it touch tabs or other whitespace?
Only when Trim is on. Trim removes leading and trailing whitespace from each line and from the final result. Tabs inside a line are left alone.
Does it preserve invisible characters like NBSP, zero-width space, or smart quotes?
Yes. We only touch \r, \n, and \r\n — every other character (NBSP, zero-width joiner, em-dash, smart quotes, emoji) passes through exactly as you pasted it. If you need to strip NBSP too, run the result through a separate find-and-replace.
Will Strip choke on a huge paste?
Strip is one of the lighter tools — a single regex pass. Up to ~500k lines / 50 MB is comfortable; beyond ~5M lines you'll feel a brief pause from string allocation, not the regex itself. The preview caps at 5,000 lines with a notice when the result gets big, but Copy and Download always return the full text.
Are "new lines" and "line breaks" the same thing?
Yes — two names for the same character. \n on Unix and Mac, \r\n on Windows, \r on classic Mac. So "newline remover", "line break remover", and "remove new lines" all describe what this tool does. The output is identical regardless of which name you searched for.