
Remove line breaks
Remove line breaks. Runs entirely on your device, nothing is uploaded.
Remove line breaks collapses a pasted text onto a single line, joining runs of two or more spaces down to one. Turn on keepParagraphs and it keeps blank-line paragraph breaks while still collapsing the breaks inside each paragraph. The join always inserts a plain space, so a word hyphenated only by the original wrap is never rejoined into one.
Questions
What exactly does keepParagraphs change?
With it off, the default, the whole text becomes one line with every line break turned into a space and double spaces collapsed to one. With it on, the text is first split on blank-line paragraph breaks, each paragraph is collapsed to one line on its own, and the paragraphs are then joined back with their blank line still between them.
Does it preserve indentation?
No. Every line break becomes a plain space, so leading spaces or tabs that formed indentation on a following line become part of the run of whitespace that gets collapsed to one space.
Will it rejoin a word that was split across two lines?
No. There is no hyphenation logic here: a word broken across a line wrap with a hyphen stays broken, now with a space in place of the line break rather than being rejoined into one word.
Can I collapse a file down to a single sentence?
That depends on what is in it, since the tool only removes line breaks and does not touch sentence-ending punctuation, so multiple sentences on separate lines end up as one line of running text, still separated by their own full stops.
What counts as a paragraph break?
A blank line, meaning one or more newline characters with only whitespace between them. Any other kind of separator, such as three dashes on their own line, is not treated as a paragraph break and is folded into the surrounding text like any other line break.