How to remove line breaks from text
- Paste your text in the box above. You can copy it from a PDF, Word, an email, ChatGPT or any website.
- Pick a mode. "Remove line breaks" turns everything into one clean block. "Keep paragraphs" removes the broken lines but keeps the space between paragraphs.
- Copy the result. The clean text appears instantly. Click Copy or Download to save it as a .txt file.
Example: before and after
What this line break remover can do
- Remove all line breaks and newlines, and replace them with a space, nothing, a comma, a
tag or any custom text. - Keep paragraphs: remove single line breaks but keep the blank line between paragraphs.
- Fix PDF text: joins broken lines and re-joins words split with a hyphen at the end of a line (for example "para-graph" becomes "paragraph").
- Remove extra spaces, tabs and double spaces, including the hidden characters that AI tools sometimes add.
- Remove empty lines and duplicate lines from lists.
- Join lines into one line with any separator, for example to turn a list into comma-separated values.
Privacy first: the tool runs completely in your browser. Your text is never uploaded to a server or saved anywhere.
Why does copied text have line breaks?
PDF files and many emails store text line by line, not paragraph by paragraph. When you copy that text, every visual line ends with a hard line break (a newline or carriage return). Pasted into Word, Google Docs, a website form or a social media post, the text breaks in strange places. Removing these line breaks puts the sentences back together.
Line break, newline and carriage return: what's the difference?
They are names for the same idea: an invisible character that starts a new line. Windows uses two characters (CR LF, written \r\n), while Mac and Linux use one (LF, written \n). This tool removes all of them, so it works with text from any device.
More free text tools
- Remove Extra SpacesClean double spaces, tabs and AI text spacing
- Remove Empty LinesDelete blank lines from any list or text
- Join LinesMerge lines into one with a comma or any separator
- Remove Paragraph BreaksFix PDF and email text, keep real paragraphs
- Transcript CleanerRemove timestamps from YouTube and SRT subtitles
- BookmarkletClean selected text on any website in one click
Frequently asked questions
How do I remove line breaks online for free?
Paste your text into the box at the top of this page. Line breaks are removed instantly. Click Copy to use the clean text anywhere. There is no signup and no limit.
Can I remove line breaks but keep paragraphs?
Yes. Choose the "Keep paragraphs" mode. Single line breaks inside a paragraph are removed, and the blank line between paragraphs stays.
How do I remove line breaks from PDF text?
Copy the text from your PDF, paste it here and choose "Fix PDF text". It joins the broken lines and also fixes words that were split with a hyphen at the end of a line.
Can I replace line breaks with commas?
Yes. In "Remove line breaks" or "Join lines" mode, set "Replace breaks with" to Comma. You can also choose a space, a
tag, nothing, or your own custom text.
Is my text safe?
Yes. All the work happens in your own browser with JavaScript. Your text is not sent to any server and is not stored.
Does it work on mobile?
Yes. The tool works on Android, iPhone, tablets and computers in any modern browser.