Replace Line Breaks in Excel Cells With Delimiters
Question details
Replace line breaks within multiple Excel cells with a chosen delimiter without editing each cell individually.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- Cells contain multiple lines that need to be converted into single, delimited lines.
- Observed behavior
- Each cell's content should remain in the same cell, with commas, semicolons, or another delimiter separating the former lines.
Identify the cells containing line breaks and choose a delimiter, such as a comma followed by a space. For Find and Replace, select only the cells you want to change.
Replace line breaks in selected Excel cells
Use Find and Replace to change line breaks directly in the selected cells.
In the worksheet, select the range containing the multiline cells.
In Excel for Windows, press Ctrl+H to open the Find and Replace dialog.
Click the Find what box and press Ctrl+J. The line-break character is invisible.
Click Replace with and type a delimiter, such as a comma and space or a semicolon.
Click Replace All, then check the selected cells to confirm the lines are separated as intended.

Use a formula to create delimited cell contents
Use SUBSTITUTE when you want to create a converted result in another column before replacing the original values.
Replace cell line breaks with WPS Spreadsheet
Use a SUBSTITUTE formula in WPS Spreadsheet to convert multiline cell contents into delimited text, then paste the results as values if needed.
- 1. Open the workbook: Open WPS Spreadsheet and use File > Open to select your workbook.
- 2. Enter a formula: In an empty cell beside the first multiline cell, enter =SUBSTITUTE(A1,CHAR(10),", "), adjusting A1 and the delimiter as needed.
- 3. Fill down: Drag the formula cell's fill handle down to convert the remaining cells.
- 4. Paste values if needed: Copy the results, select the original cells, and choose Paste Special > Values to replace them with the converted text.
- 5. Save the workbook: Choose File > Save As and select an Excel format such as XLSX.

Frequently Asked Questions
How do I find a line break in an Excel cell?
In Excel for Windows, select the cells, press Ctrl+H, click Find what, and press Ctrl+J. The line-break character is not visibly displayed.
Can I replace line breaks with semicolons instead of commas?
Yes. In the Replace with box, enter a semicolon or any other delimiter before clicking Replace All.
Will replacing line breaks split the text into separate cells?
No. Find and Replace changes the characters within each selected cell; it does not split the text into separate cells.
Why does a formula leave some line breaks behind?
Some imported text contains carriage returns as well as line feeds. You can remove carriage returns with a nested formula such as =SUBSTITUTE(SUBSTITUTE(A1,CHAR(13),""),CHAR(10),", ").




