creatorvalet Search

Remove line breaks

Join text that was split across lines — and keep the paragraph breaks that matter.

  • SECURE
  • NO UPLOADS
  • NO SIGNUP
  • BROWSER BASED
  • FREE
  • FOREVER.

Support us with a link or a share

waiting

Mode
№ 4544waiting

Nothing at the counter yet.

The mode you actually want

Nearly every line-break remover offers exactly one behavior: delete every line break, everywhere. That is almost never what someone needs. It turns a three-page document into one unbroken paragraph, and the structure that made it readable is gone.

The common case is text copied out of a PDF, where a break appears at the end of every visual line rather than at the end of every sentence. What you want there is to rejoin the lines within each paragraph while keeping the blank line that separates one paragraph from the next. That is the default mode here.

Why PDFs do this

A PDF does not store paragraphs. It stores glyphs at coordinates on a page — this character at this position, that character next to it. Where a line ends is a consequence of the page layout, not of the writing.

When you select and copy, the viewer reconstructs a reading order and inserts a line break wherever the text moved down the page. The result looks correct in the PDF and arrives with a break every seventy characters. Nothing is broken; the paragraph structure simply was never stored in the first place.

Three ways to remove line breaks

Join paragraphs merges lines within each block of text and keeps blank lines between blocks. This is the PDF case, and the one you want most of the time.

Remove all collapses everything to a single line. Useful when pasting into a field that accepts only one line, or when preparing a value to drop into a single spreadsheet cell.

Trim line ends touches no line breaks at all. It removes spaces and tabs at the end of each line — invisible characters that quietly break Markdown formatting, produce phantom changes in version control, and make string comparisons fail for no visible reason. Typographic spaces such as a non-breaking space remain content and are not trimmed.

Unicode line breaks

A line is not always separated by the familiar Unix or Windows marker. Vertical tab, form feed, next line, Unicode line and paragraph separators, and the three information separators are logical line boundaries too. Every mode recognizes the same complete set: joining modes remove them, while Trim line ends normalizes them to ordinary Unix line endings and leaves the line structure intact.

Words split across two lines

Text set in narrow columns often breaks a word in half: informa- at the end of one line and tion at the start of the next. Joining those two lines the way every other pair is joined would put a space after the hyphen — informa- tion — and that is a form no text has ever wanted. So a break that lands directly after a hyphen between two word characters carries nothing at all, and you get informa-tion.

The hyphen itself stays. Whether it was a typesetting artifact or a real part of the word is not something a line-break tool can know: informa-tion should close up into one word, and well-known must not, and nothing in the two lines tells them apart. That takes a dictionary and the surrounding paragraph structure, which is what PDF to text works with when it rebuilds paragraphs out of the document itself. If your text is still in a PDF file, start there rather than pasting what the viewer gives you.

Japanese and Chinese text

A line break between two Japanese or Chinese characters carries no space. Those scripts wrap at nearly any character, so the break is a property of the column width and not a word boundary — putting a space where it was leaves a visible gap in the middle of a sentence. A break with a CJK character on both sides therefore closes up completely, while a break between two Latin words in the same paste still becomes a space.

Korean is left alone on purpose. Hangul is written with spaces between words and wraps mostly at them, so closing those breaks up would swallow a real word boundary rather than remove an invented one.

When the result comes back empty

If what you paste holds only spaces, tabs and line breaks, there is nothing to join and the output is empty. The receipt says empty instead of counting a line that is not there, and Copy and Download are withheld, since they would hand you an empty file. It usually means the copy carried formatting but no text — a table of blank cells, or a selection that ended up holding only the layout. Text cleaner is the tool for looking at what a paste actually contains, including the zero-width and invisible characters that make text look present when it is not.

Lines that are a list, not a paragraph

Not everything with line breaks is prose. When each line is an entry — names, SKUs, URLs, a column pasted out of a spreadsheet — the line is the unit, and joining them destroys the only structure the text had. Sort lines puts such a list in order and Remove duplicate lines drops the repeats, both keeping one entry per line. Of the three modes here, only Trim line ends belongs to that kind of text: it clears the invisible spaces at the end of each entry and leaves every break where it is.

Windows and Unix line endings

Text from Windows marks a line break with two characters, a carriage return followed by a newline. macOS and Linux use the newline alone. Mixing the two produces duplicate blank lines, and a stray carriage return is invisible in most editors while still breaking whatever reads the file next.

All three modes normalize line endings before doing anything else, so pasted Windows text behaves exactly like pasted Unix text and you never have to work out which one you have.

Have an idea for this tool?

Tell us what would make this tool more useful, or suggest another tool you would like us to build.

Questions

Why does my PDF text have a line break on every line?

PDFs store text positioned on the page rather than as flowing paragraphs. Copying it out gives you a break wherever the line ended visually, not where the sentence ended. Paragraph mode rejoins those lines while keeping real paragraph breaks intact.

What is the difference between the modes?

Remove all collapses every recognized line break into a single line. Join paragraphs merges lines within each paragraph but keeps blank lines between paragraphs. Trim line ends removes only ASCII spaces and tabs at the end of each line.

What happens to a word split by a hyphen at the end of a line?

The two halves are joined without a space, so informa- followed by tion becomes informa-tion rather than informa- tion. The hyphen itself stays, because nothing in those two lines says whether it was added by the typesetting or belongs to the word the way it does in well-known. Rebuilding the word needs the document structure, which is what the PDF to text tool works from.

Does it work with Japanese or Chinese text?

Yes. A line break between two Japanese or Chinese characters carries no space, because those scripts wrap at almost any character and the break is not a word boundary. Such breaks close up completely, while breaks between Latin words in the same text still become spaces. Korean is left alone, since Hangul separates words with real spaces.