This post will guide you how to use Google Sheets SPLIT function with syntax and examples.
The Google Sheets SPLIT function used to divide text string around a specified character or delimiter and put each separate pieces into a separate cell in the row.
The SPLIT function can be used to divide a text string or text value around a given delimiter in google sheets. The purpose of this function is to split a text string based on a delimiter.
The SPLIT function is a build-in function in Google Sheets and it is categorized as a Text Function.
The syntax of the SPLIT function is as below:
=SPLIT(text, delimiter, [split_by_each], [remove_empty_text])
Where the SPLIT function arguments are:
- text -This is a required argument. The text string or value that you want to split. It can also be a cell reference or a cell or the output of a nested formula. it should be a string and not an array result.
- delimiter -This is a required argument. The delimiter is the character or characters that used to split the text. By default, each character in delimiter is considered individually. For example, if delimiter is “test”, then text string is divided around the characters “t”,”h” and “e”. You can set split_by_each argument to FALSE to disable this behavior.
- split_by_each -This is an optional argument. This argument will control whether or not to divide text around each character contained in delimiter argument. The default value is TRUE. And the TRUE behavior will split text by individual characters in the delimiter. And The FALSE behavior only divides text by the entire delimiter.
- remove_empty_text – This is an optional argument. This argument will control whether or not to remove empty text messages from the split results. The default value is TRUE.
- Delimiters are case sensitive. So “lowercase “g” is only splits on lower-cases g’s in the text string.
- The SPLIT function requires enough cells for its output. If it splits a text string into 3 elements, and it requires 3 empty cells on the same row to place them. If there is already data in those cells, it does not overwrite those cells, then it shows a #REF! error message.
Google Sheets SPLIT Function Examples
The below examples will show you how to use google sheets SPLIT function to split a text string around a given delimiter.
#1 To separate a list of names in Cell B1 with “,” delimiter character, just using the following formula:
The above SPLIT formula will separate names using the comma character as a delimiter. And the result is 4 cells, and each cell contain a name. and you can notice that there is one blank cell, because the text string in Cell B1 has two adjacent commas with a space character between those two commas.