Remove line breaks from text copied out of a PDF, and keep the paragraphs
Published
Open Remove line breaksPaste the copied text into remove line breaks, set Paragraphs to Keep paragraphs, and copy the result. Every break inside a paragraph is replaced by a space, so sentences flow again, while the blank line between paragraphs stays.
Why PDF text breaks like this
A PDF stores where each line of text sits on the page, not where sentences and paragraphs begin and end. When you copy from it, most readers put a line break at the end of every printed line. Pasted into an email, a document or a form, the text stops short of the edge every few words. The same happens with text copied from some emails, old plain-text files and subtitles.
Steps
- Copy the text from the PDF and paste it into Text with line breaks.
- Under Replace each line break with, keep Space. This is what you want for prose.
- Under Paragraphs, choose Keep paragraphs. The lines inside each paragraph are joined, and the blank line between paragraphs is kept. Choose One block only if you want everything in a single paragraph.
- Under Extra spaces, keep Tidy spaces. It trims each line and turns runs of spaces into one, so the join never leaves a double space.
- Check the Result. The status line says how many line breaks were removed.
- Press Copy and paste the text where it belongs.
Before and after
Pasted from a PDF:
The committee met on Tuesday to review
the proposal. After a long discussion,
members agreed to a second reading.
The next meeting is planned for
the first week of March.
With Space, Keep paragraphs and Tidy spaces:
The committee met on Tuesday to review the proposal. After a long discussion, members agreed to a second reading.
The next meeting is planned for the first week of March.
When the paragraphs run together
Keep paragraphs relies on a blank line between paragraphs. Some PDFs copy out with no blank line at all, so every line looks the same and the paragraphs merge into one. Two ways to fix that:
- Before converting, press Enter at the end of each paragraph in the box to add a blank line, then convert.
- Or convert with One block, then add the paragraph breaks in the result by hand. For a page or two this is quick.
Things this tool does not fix
PDF copying causes a few other problems that need a manual pass:
- Words split by a hyphen at the end of a line, such as
infor-thenmation, come out asinfor- mation. Search the result for "- " (a hyphen and a space) and join those words. Check each one, because some hyphens are real, as in "well- and badly-made". - Headers, footers and page numbers copied with the text stay in. Delete them from the result.
- Columns in a two-column PDF can copy in the wrong order. Copy one column at a time.
- Ligatures and odd characters such as
fiin place of "fi" depend on how the PDF was made. They are left as they are.
Other replacements
The same tool handles other jobs by changing Replace each line break with:
| Choice | Puts in place of each break | Use it for |
|---|---|---|
| Space | One space | Prose from a PDF, email or subtitle file |
| Comma | A comma and a space | Turning a list into one line, see list to comma-separated |
| Nothing | Nothing at all | Joining a long code, key or number split over lines |
| Custom | Your own text; it starts as a vertical bar with a space each side | Separators such as a semicolon or a slash |
Empty lines are always dropped, so you never get two separators in a row from a blank line.
After the cleanup
Once the text flows, two other tools are often next. If the PDF text came out in capitals, the case converter can turn it into sentence case. If it has to fit a limit, paste it into the word counter; the line breaks you removed no longer count as characters.
Questions
Is the text uploaded?
No. The lines are joined in your browser and the text stays on your device.
Does it work with text copied from Word or a web page?
Yes, with any text. Word documents and web pages usually keep paragraphs already, so the tool is most useful for PDFs, emails and plain-text exports.
Will it remove the breaks in a list I want to keep?
Yes. Every break inside a block of text is joined, list or not. Paste only the part that needs joining, and copy the list across separately.
Can I undo it?
The original stays in the top box until you clear it, so you can change the options at any time and the result updates.
Remove line breaks
Join lines from a PDF or email with a space, comma or your own text.
Open Remove line breaksRelated tools
- Word & character counter: Count words, characters, sentences and reading time.
- Case converter: Change text between UPPER, lower, Title and more.