I pressed return to make a new line in a cell of my Google Spreadsheet. That just moved the cursor to the next cell.
How does one add a new line in a cell?
When you're focused on the cell press enter to get into edit mode:
CHAR(10)
.
Commented
Dec 9, 2013 at 13:47
New Line in Cell Formula
>> CHAR(10)
=Concatenate("Line 1", CHAR(10), "Line 2", CHAR(10), "Line 3")
=Join(CHAR(10), "Line 1", "Line 2", "Line 3")
A new line is also known as a Line Feed
. The hexadecimal Unicode Control Code
for a Line Feed is U+000A
. Therefore, the decimal value of a Line Feed is 10.
This decimal value can be used in the CHAR(...) function in Google Sheets to return the desired character.
Note: Dez's answer does not work for cell formulas. I was searching for adding new-lines in cell formulas, and this StackExchange question popped up. Therefore, I added the above for those that need new lines in formulas. The below is a snapshot of Dez's answer for completeness :)
Dez's Answer
In Edit Mode
Windows/Linux: Ctrl + Enter or Alt + Enter
Mac: Command/option(Alt) + Enter
=JOIN(Char(10), A1,A2,A3...)
=TEXTJOIN(CHAR(10), 1, "Line 1", "Line 2", "Line 3")
may even be better to treat empty values
Commented
Nov 11, 2023 at 9:48