Smart Systems for Home

Plain how-to guides for smart home, security and home Wi-Fi

Char 10 Excel: How to Insert Line Breaks in Formulas

· 5 min read · Home Tech

In this article
  1. What You'll Need
  2. Step-by-Step
  3. Common Mistakes
  4. Tips
  5. Troubleshooting
  6. Frequently Asked Questions

To use CHAR(10) in Excel, you must wrap it in a formula using the ampersand (& symbol) to combine text strings and then enable Wrap Text in the cell formatting. For example, ="First Line"&CHAR(10)&"Second Line" will create a line break between the two phrases. This function is essential because Excel does not recognize a standard Enter key press within a formula as a visual line break; it requires the specific ASCII character code for a line feed to trigger the move to a new line.

What You'll Need

  • Microsoft Excel (Desktop version for Windows or macOS).
  • A dataset where you need to combine multiple columns into one cell with distinct lines (e.g., combining a Name, Address, and City).
  • Basic familiarity with the formula bar and the Home tab on the ribbon.

Step-by-Step

  1. Identify the cells you want to combine: Locate the data you wish to merge. For instance, if Cell A2 contains "John Doe" and Cell B2 contains "123 Maple St", you want these to appear on separate lines in Cell C2.
  2. Start your formula: Click on the target cell (C2) and type the equals sign = to begin the formula.
  3. Select the first piece of data: Click on cell A2 or type the cell reference. Your formula should now look like =A2.
  4. Add the concatenation symbol: Type the ampersand &. In Excel, the ampersand tells the program to join two different pieces of information together.
  5. Insert the CHAR(10) function: Type CHAR(10). This specific function tells Excel to insert the character associated with the number 10 in the ASCII table, which is the "Line Feed" character.
  6. Add the second concatenation symbol: Type another ampersand & to prepare for the next piece of data.
  7. Select the second piece of data: Click on cell B2. Your complete formula should now read =A2&CHAR(10)&B2.
  8. Press Enter: After pressing Enter, you might notice that the result looks like a single line of text or that the text is cut off. This is normal and is the most common point of confusion.
  9. Enable Wrap Text: While the cell is still selected, go to the Home tab on the top ribbon. In the Alignment group, click the Wrap Text button. As soon as this is activated, the CHAR(10) command will trigger, and the text will split into two lines.
  10. Adjust Row Height: If the text still looks cramped or the second line is hidden, hover your mouse over the boundary between the row numbers on the far left. Click and drag the boundary down to increase the row height so both lines are visible.

Common Mistakes

The most frequent error is forgetting to turn on Wrap Text. Without this setting, Excel ignores the line feed instruction and displays the text in one continuous string, often with a small space or no space at all where the break should be. Another common mistake is using a comma instead of an ampersand. While the CONCATENATE or CONCAT functions can also be used, the ampersand is the most reliable way to manually stitch strings together.

Users also frequently forget to include spaces around the CHAR(10) function when dealing with static text. For example, if you write ="Hello"&CHAR(10)&"World", it works perfectly. However, if you are adding a label like ="Name: "&A2&CHAR(10)&"City: "&B2, ensure the spaces are inside the quotation marks so the labels don't run directly into the data.

Tips

For more complex strings, you can use CHAR(10) multiple times in a single formula. For example, if you are creating a mailing label with a name, street, city, state, and zip, your formula would look like: =A2&CHAR(10)&B2&CHAR(10)&C2&" "&D2&" "&E2. This allows you to create a perfectly formatted block of text within a single cell.

If you are using a Mac, be aware that some older versions of Excel for Mac occasionally required CHAR(13) (the Carriage Return) instead of CHAR(10). However, in modern versions of Office 365, CHAR(10) is the universal standard for line breaks across both Windows and macOS. If CHAR(10) doesn't work on an ancient Mac version, try 13.

To make your formulas easier to read, you can use the TEXTJOIN function in newer versions of Excel. Instead of repeating ampersands and CHAR(10), you can use =TEXTJOIN(CHAR(10), TRUE, A2, B2, C2). This tells Excel to use a line break as the delimiter between every cell listed in the range, significantly shortening the formula length.

Troubleshooting

The text is still on one line: First, double-check that Wrap Text is highlighted in the Home tab. If it is already on, try toggling it off and back on again. If the cell is part of a merged group, ensure the merge settings aren't overriding the alignment.

I see the formula instead of the result: This usually happens if the cell is formatted as "Text" instead of "General". Go to the Home tab, change the Number Format dropdown to "General", then click into the formula bar and press Enter again.

The line break is there, but I can't see the second line: This is almost always a row height issue. Excel does not always automatically expand the row height when using CHAR(10). Manually drag the row header down or double-click the boundary between the row numbers to "AutoFit" the height to the content.

The formula returns a #VALUE! error: Check your syntax. Ensure every piece of static text is enclosed in double quotes (e.g., " " or "- ") and that every separate element is joined by an ampersand. A missing quote or a stray comma inside the formula will trigger this error.

Frequently Asked Questions

Can I use CHAR(10) in a VLOOKUP?

Yes, you can include CHAR(10) within a formula that uses VLOOKUP if you are concatenating the result of the lookup with other text. For example: ="Result: "&VLOOKUP(...)&CHAR(10)&"Date: "&C2.

Is there a difference between CHAR(10) and Alt+Enter?

Alt+Enter is a manual shortcut used while typing directly into a cell to create a line break. CHAR(10) is the functional equivalent used within formulas to automate that process for hundreds of cells at once.

Does CHAR(10) work in Google Sheets?

Yes, CHAR(10) works identically in Google Sheets. You must still ensure that the cell's wrapping setting is set to "Wrap" rather than "Overflow" or "Clip" to see the effect.

Can I use this to create a list in a single cell?

Yes. By combining CHAR(10) with a bullet point character (like CHAR(149)), you can create a formatted list. Example: =CHAR(149)&" Item 1"&CHAR(10)&CHAR(149)&" Item 2".

Why does my formula show the number 10 instead of a break?

This happens if you typed =10 or forgot the word "CHAR". You must use the full function CHAR(10) for Excel to interpret it as a character code rather than a numeric value.