Remove Line Breaks
Remove line breaks from text and join all lines with a custom separator.
(single space)
Why Remove Line Breaks?
Multi-line text often needs to be converted to a single line for use in spreadsheets, JSON strings, SQL queries, command-line arguments, or email subject lines. Text copied from PDFs or documents frequently contains unwanted line breaks that break formatting when pasted elsewhere.
Custom Separator Options
The default separator is a single space, which joins lines naturally into flowing prose. You can change this to any character or string:
- Space — joins lines into a single paragraph
- Comma + space (", ") — creates a comma-separated list
- Pipe (" | ") — creates a pipe-delimited string common in data processing
- No separator ("") — concatenates lines with no separator between them
Common Use Cases
- Fixing text copied from PDFs that has unwanted line breaks mid-sentence
- Converting a list of items into a comma-separated string
- Preparing text for use in a single-line JSON string value
- Joining SQL WHERE clause values from a newline-separated list
- Combining lines from a data export into a delimited format