Get the Chrome extension
Free · No sign-up · Runs in your browser

Paragraph to Single Line Converter: remove line breaks in one click.

Paste text with broken lines and get one clean line. Join with a space, comma or pipe, keep your paragraphs if you want to, and copy the result as plain text, a JSON string or a CSV cell.

Last updated: October 30, 2026

2 · Single-line result
3 · Options

Handles Windows, Mac and Linux line endings and the Unicode line and paragraph separators. Your text never leaves your browser.

0 characters0 words0 lines in0 lines out0 breaks removed
The basics

What is a paragraph to single line converter?

A paragraph to single line converter removes the line breaks from text and joins everything into one line. You paste text that is split across many lines, and it returns the same words on one line, with a space, comma or other separator where each break was.

It fixes text copied from PDFs, emails and chats, turns lists into one line, and prepares text for forms, spreadsheets and code. Unlike a plain find and replace, it handles Windows, Mac and Linux line endings, can keep your paragraphs, and can output a JSON string or CSV cell.

If the text also carries styling from a document, run it through Remove Text Formatting first. To fix capitals afterwards, use the sentence case converter or the case converter.

Examples for each option
OptionYou pasteYou get
Default: join with a spaceThis is a paragraph
that was broken
across lines.
This is a paragraph that was broken across lines.
Windows line endingsline one\r\nline twoline one line two
Unicode line separatorone\u2028twoone two
Comma and spaceapples
oranges
bananas
apples, oranges, bananas
Pipea
b
c
a|b|c
Keep paragraph breaksFirst line
continues here.

Second paragraph
also wraps.
First line continues here.

Second paragraph also wraps.
Join hyphenated wordsan inter-
national team
an international team
Remove duplicate linesred
blue
red
green
red,blue,green
JSON stringHe said "hi"
then left
"He said \"hi\" then left"
CSV cellHe said "hi"
then left
"He said ""hi"" then left"
How it works

How to convert a paragraph to a single line

It takes four steps and works for any amount of text.

01

Paste your text

Paste text with line breaks, or open a .txt file. Text copied from PDFs, emails, chats and spreadsheets all work.

02

Choose how to join

Pick a space, comma, pipe or custom text. Turn on Keep paragraph breaks if blank lines separate paragraphs you want to keep.

03

Pick the output

Choose plain text, a JSON string or a CSV cell. The result updates as you change an option.

04

Copy or download

Press Copy result or save a .txt file. Your original text stays in the input box.

Options

Options explained

Each option changes one thing, so you can combine them to match the text you have.

Options and what they do
OptionWhat it doesExample
Join lines withThe text placed where each line break was. Space is best for sentences, and comma or pipe suits lists.a, b, c
Keep paragraph breaksJoins the lines inside each paragraph but keeps one blank line between paragraphs.Paragraph one.

Paragraph two.
Join words split by a hyphenWhen a line ends with a hyphen after a letter and the next line starts lowercase, the two parts are joined without the hyphen.inter-
national becomes international
Collapse repeated spacesReplaces runs of spaces or tabs with one space inside each line.a b becomes a b
Trim every lineRemoves spaces at the start and end of each line before joining. text becomes text
Remove duplicate linesKeeps the first copy of each repeated line. Useful for lists.red, blue, red becomes red, blue
Output asPlain text, a JSON string with quotes and escapes, or a CSV cell with doubled quotes."He said ""hi"""
Line endings

Line breaks, newlines and carriage returns

Different systems end lines with different characters. The converter treats all of these as line breaks.

Line break characters
NameCharacterWhere it is used
LF\nUnix, Linux and modern macOS
CRLF\r\nWindows
CR\rClassic Mac OS
NELU+0085Unicode next line; software handles it inconsistently
LSU+2028Unicode line separator; treated as a line terminator by ECMAScript
PSU+2029Unicode paragraph separator; treated as a line terminator by ECMAScript
VT and FF\v and \fRare control characters this tool also treats as line breaks

Source: Wikipedia, Newline.

Use cases

When to remove line breaks

It saves the most time when the lines were broken by a layout, not by you.

Text copied from PDFs

Copying from a PDF often keeps the line ends of the printed layout. Join them to get a normal paragraph, and turn on hyphen joining for split words.

Emails and chat messages

Remove forced line wraps from quoted emails or chat logs before you paste them into a document or form.

Lists into one line

Turn one item per line into a comma, semicolon or pipe separated line for tags, keywords or a spreadsheet cell.

Data and CSV imports

Put multi-line addresses or notes on one line, or output them as a CSV cell with the quotes already escaped.

Strings in code

Output a JSON string to paste into code, config files or an API request without escaping quotes by hand.

Prompts and short fields

Flatten text for form fields, social bios or tools that do not accept line breaks.

Other tools

Remove line breaks in Word, Excel and code

You can do the same in other tools. These are the quickest ways.

Microsoft Word

Press Ctrl+H, put ^p (paragraph mark) or ^l (manual line break) in Find what, a space in Replace with, then Replace All. See the Word MVP guide to special characters.

Excel and Google Sheets

Use =SUBSTITUTE(SUBSTITUTE(A1,CHAR(13),""),CHAR(10)," ") to turn the line breaks in a cell into spaces. In Excel for Windows you can also press Ctrl+J in the Find box. See the SUBSTITUTE function.

Text editors and code

Search with a regular expression that matches \r\n|\r|\n and replace it with a space. The code on this page does the same in JavaScript and Python.

For developers

Remove line breaks in JavaScript and Python

Match all three line endings with one regular expression, with the Windows \r\n first so it is not counted twice. The MDN page on replace explains the g flag, and the Python re documentation covers re.sub.

// JavaScript
const oneLine = text.replace(/\r\n|\r|\n/g, " ");

# Python
import re
one_line = re.sub(r"\r\n|\r|\n", " ", text)
Good to know

What a line break remover cannot know

Joining lines is a mechanical rule. These limits explain the few places where you should check the result.

  • Wrapped lines look like paragraphs

    When there are no blank lines, a tool cannot tell a wrapped line from a deliberate one. Leave Keep paragraph breaks off and everything becomes one line.

  • Hyphen joining can be wrong

    A line ending in a real hyphen, such as well- followed by known, becomes wellknown. Use it for hyphenated line wraps and review the result.

  • Spaces may need a second look

    Collapse and Trim only touch spaces and tabs. Other invisible characters, such as zero-width spaces, are left as they are.

  • Join text matters

    Joining with Nothing glues words together. Use it only for data such as codes, not for sentences.

  • JSON and CSV need checking

    The JSON option escapes quotes and backslashes the way JavaScript does. Check the result in the tool that will read it.

  • Large files

    The tool runs in your browser, so very large files may be slow on an old device.

Sources

Where these facts come from

The line-ending facts and code on this page follow the sources below. Last reviewed: October 30, 2026. Every example in the table above was run through the converter before publishing.

Sources and further reading
FAQ

Paragraph to single line converter FAQ

Short answers to what people ask most about removing line breaks.

What is a paragraph to single line converter?

A paragraph to single line converter removes the line breaks from text and joins everything into one line. This one lets you choose the joiner, keep paragraphs, and copy the result as plain text, a JSON string or a CSV cell.

How do I remove line breaks from text?

Paste your text into the box above. The line breaks are replaced with a space straight away, and you can copy the result or download it as a .txt file. Change the Join lines with option for a comma, pipe or custom text.

What is the difference between a line break and a paragraph break?

A line break moves text to the next line. A paragraph break usually means an empty line between blocks of text. Turn on Keep paragraph breaks to join the lines inside each paragraph and keep the blank line between paragraphs.

How do I join lines but keep my paragraphs?

Turn on Keep paragraph breaks. Each paragraph becomes one line, and one blank line stays between paragraphs.

Why does text copied from a PDF have line breaks in the middle of sentences?

Copying from a PDF often keeps the line ends of the printed layout. Paste it here, turn on Join words split by a hyphen for words broken across lines, and use Keep paragraph breaks if blank lines separate paragraphs.

How do I turn a list into a comma-separated line?

Paste one item per line and set Join lines with to Comma or Comma and space. Turn on Remove duplicate lines if the list repeats items.

What are \n, \r and \r\n?

They are the codes for line breaks. \n (LF) is used by Unix, Linux and modern macOS, \r\n (CRLF) by Windows and \r (CR) by classic Mac OS. See the Wikipedia article on newlines. This tool handles all three and the Unicode line separators.

How do I remove line breaks in Word or Excel?

In Word, open Find and Replace and search for ^p for paragraph marks or ^l for manual line breaks, replacing with a space. In Excel, use =SUBSTITUTE(SUBSTITUTE(A1,CHAR(13),""),CHAR(10)," ") or Find and Replace with Ctrl+J in the Find box. See the Microsoft SUBSTITUTE guide.

Does it remove extra spaces too?

Yes, by default. Collapse repeated spaces and Trim every line are on, so runs of spaces become one space and the ends of each line are cleaned. You can turn both off.

Can I use the output in JSON or CSV?

Yes. Set Output as to JSON string for a quoted, escaped string, or CSV cell for a quoted value with doubled quotes. Check the result in the tool that reads it.

Is my text saved or sent anywhere?

No. The conversion runs in your browser using JavaScript, so your text is not uploaded or stored. There is no character limit and no sign-up.