Remove line breaks
Turn text with a break at the end of every line back into flowing paragraphs, or a list into one line with commas. Extra spaces and words split by a hyphen can go too.
Cleaned up in your browser. Your text is never sent or stored.
How it works
From broken lines to paragraphs
Text copied from PDFs, old emails and some websites often has a line break at the end of every line. Pasted elsewhere, it no longer wraps to fit, and editing it is fiddly. This tool joins the lines again:
- Keep paragraphs joins lines but keeps empty lines between paragraphs.
- One line joins everything into a single line.
- Join lines with decides what goes where each break was: a space for running text, a comma or a comma and a space to turn a list into one line, or nothing for codes and numbers split over several lines.
- Remove extra spaces turns double spaces and tabs into single spaces.
- Rejoin words split by a hyphen turns "infor-" at the end of a line and "mation" on the next back into "information".
Want to know how long the result is? The text carries over to the word counter and the character counter.
More tools
More text tools
- Word counterWords, sentences, paragraphs, reading time and keyword density.
- Character counterCharacters with and without spaces, checked against limits for posts, bios, ads and SMS.
- Reading time calculatorWords to minutes: how long your text takes to read or say out loud.
- Case converterUPPERCASE, lowercase, Title Case, Sentence case, camelCase and more.
- Remove duplicate linesClean up lists: drop repeated and blank lines, and sort what is left.
Frequently asked questions
Why does text from a PDF have line breaks everywhere?
A PDF stores text as lines placed on a page, not as flowing paragraphs. When you copy it, every line ends with a break, so the text no longer reflows when pasted into an email, a document or a form.
How are paragraphs kept?
With "Keep paragraphs", the line breaks inside a paragraph are replaced with a space (or whatever you join lines with), while an empty line between paragraphs stays a paragraph break. If your text has no empty lines between paragraphs, everything ends up as one paragraph.
How do I turn a list into comma-separated text?
Paste one item per line, choose "One line" and join lines with "Comma + space": apples, pears and plums on separate lines become "apples, pears, plums". Choose "Comma" for values without spaces, for example for a spreadsheet or code. Empty lines are skipped, so you never get two commas in a row.
When should I join lines with nothing?
For things that were split over several lines but belong together without spaces, such as a long number, a code, an encoded string or a URL broken across lines in an email.
What about words split with a hyphen at the end of a line?
Tick "Rejoin words split by a hyphen" to turn "infor-" at the end of one line and "mation" on the next into "information". It only joins when the next line starts with a lowercase letter. It is off by default because some words really have a hyphen there: "well-known" split after its hyphen becomes "wellknown", so read the result through.
What does "Remove extra spaces" do?
It turns runs of spaces and tabs into a single space and trims spaces from the start and end of each paragraph. Text copied from PDFs and websites often has double spaces or indents you can't see until you paste it.