To break up a string in Excel, the most efficient method is the TEXTSPLIT function, which allows you to split a text string into multiple cells based on a specific character or "delimiter" (such as a comma, space, or semicolon). For those using older versions of Excel that do not support TEXTSPLIT, the combination of LEFT, RIGHT, MID, and FIND functions serves as the manual alternative to isolate specific parts of a string.

What You'll Need

  • A computer with Microsoft Excel installed (Microsoft 365 or Excel 2021 for TEXTSPLIT; any version for LEFT/RIGHT/MID).
  • A dataset containing strings of text that need to be separated (e.g., "First Name, Last Name" or "City, State, Zip").
  • An understanding of your "delimiter," which is the character that separates the data points within the string.

Step-by-Step

Method 1: Using the TEXTSPLIT Function (Modern Excel)

TEXTSPLIT is a dynamic array function. This means you only enter the formula in one cell, and Excel automatically "spills" the results into the adjacent cells to the right.

  1. Identify your source cell: Locate the cell containing the string you want to break up. For this example, assume the text "Apple, Banana, Cherry" is in cell A2.
  2. Select the destination cell: Click on the cell where you want the first piece of split data to appear (e.g., B2).
  3. Enter the function: Type =TEXTSPLIT( into the formula bar.
  4. Define the text argument: Click on cell A2 or type "A2". This tells Excel which string to break up.
  5. Define the column delimiter: Type a comma, then put your delimiter inside double quotation marks. If your data is separated by commas, type ", ". The formula should now look like =TEXTSPLIT(A2, ", ").
  6. Press Enter: Excel will instantly split the string. "Apple" will appear in B2, "Banana" in C2, and "Cherry" in D2.
  7. Apply to other rows: Hover over the bottom-right corner of cell B2 until the cursor becomes a small black cross, then click and drag downward to apply the split to the rest of your column.

Method 2: Using LEFT, MID, and FIND (Older Excel Versions)

If you are on an older version of Excel, you cannot use a single function to split a string. You must use a combination of functions to "hunt" for the delimiter and extract the text around it.

  1. Extract the first part (Before the delimiter): To get everything before the first comma in cell A2, use the LEFT function combined with FIND. Enter: =LEFT(A2, FIND(",", A2)-1). The FIND function locates the position of the comma, and the LEFT function grabs all characters to the left of that position minus one (to avoid including the comma itself).
  2. Extract the middle part (Between delimiters): This is more complex and requires the MID function. To find text between the first and second comma, you must tell Excel where to start and how many characters to take. A common formula is: =MID(A2, FIND(",", A2)+1, FIND(",", A2, FIND(",", A2)+1) - FIND(",", A2)-1).
  3. Extract the last part (After the last delimiter): Use the RIGHT function combined with LEN and FIND. Enter: =RIGHT(A2, LEN(A2) - FIND(",", A2)). This calculates the total length of the string and subtracts the position of the comma to isolate the remaining text on the right.

Method 3: Using Text to Columns (Non-Formula Approach)

While not a function, the "Text to Columns" wizard is the fastest way to break up strings if you do not need the results to update automatically when the source text changes.

  1. Highlight the data: Select the column or range of cells containing the strings you want to split.
  2. Open the tool: Go to the Data tab on the top ribbon and click Text to Columns.
  3. Choose the file type: In the wizard, select Delimited and click Next. (Delimited means the data is separated by a specific character).
  4. Select the delimiter: Check the box for the character that separates your data (e.g., Comma, Tab, or Space). If your delimiter is something else, like a pipe (|), check Other and type the character in the box.
  5. Set the destination: Click Next, then choose the Destination cell. By default, Excel will overwrite your original data; change this to an empty column (e.g., $B$2) to keep your original strings intact.
  6. Finish: Click Finish to execute the split.

Common Mistakes

  • Forgetting Quotation Marks: In functions like TEXTSPLIT or FIND, the delimiter must be enclosed in double quotes (e.g., ","). If you type =TEXTSPLIT(A2, ,), Excel will return a formula error.
  • Ignoring Leading/Trailing Spaces: If your string is "Apple, Banana", splitting by a comma alone will leave a space before "Banana". To fix this, use a comma and a space as your delimiter (", ") or wrap your formula in the TRIM function: =TRIM(TEXTSPLIT(A2, ",")).
  • Overwriting Existing Data: When using TEXTSPLIT or Text to Columns, Excel needs empty cells to the right to place the split data. If there is already data in those cells, TEXTSPLIT will return a #SPILL! error.
  • Incorrect Indexing in MID: When using the MID function, users often forget to add "+1" to the FIND result. If the comma is at position 5, starting the MID function at position 5 will include the comma in your result; starting at 6 ensures you only get the actual text.

Tips

  • Handle Multiple Delimiters: TEXTSPLIT can handle multiple different delimiters at once. If your string is "Apple;Banana,Cherry", you can use an array of delimiters: =TEXTSPLIT(A2, {";", ","}). This tells Excel to split the string whenever it encounters either a semicolon or a comma.
  • Split into Rows instead of Columns: If you want your string to break up vertically into a list rather than horizontally across a row, use the third argument of TEXTSPLIT. The formula =TEXTSPLIT(A2, ",", "") (leaving the column argument blank but filling the row argument) will spill the data downward.
  • Combine with UPPER or LOWER: If you are splitting names and want them standardized, wrap the function: =UPPER(TEXTSPLIT(A2, ", ")) will split the string and convert all resulting text to uppercase.
  • Use Tables for Dynamic Ranges: If you convert your data range into an official Excel Table (Ctrl+T), your splitting formulas will automatically expand to new rows as you add more data to the bottom of the table.

Troubleshooting

If your formula is not working as expected, follow these steps in order:

  1. Check for #SPILL! Errors: This occurs when there is something blocking the path of the split data. Clear all cells to the right of your formula cell and the error should disappear.
  2. Verify the Delimiter: Sometimes a character looks like a comma or a space but is actually a non-breaking space or a special character from a different encoding. Copy the character directly from the cell and paste it into your formula's quotation marks.
  3. Check for #VALUE! Errors: This usually happens in the LEFT/FIND method if the delimiter is not found in the cell. To prevent this, wrap your formula in IFERROR: =IFERROR(LEFT(A2, FIND(",", A2)-1), A2). This tells Excel to just return the original text if no comma is found.
  4. Inspect Data Types: Ensure the cell is formatted as "General" or "Text". If the cell is formatted as "Text" before you type the formula, Excel may treat the formula as a literal string and show the text of the formula instead of the result. Change the format to General and press Enter again.

Frequently Asked Questions

Can I split a string by a fixed number of characters?

Yes. If you don't have a delimiter (like a comma) but know the string is always 10 characters per segment, use the MID function. For example, =MID(A2, 1, 10) gets the first 10 characters, and =MID(A2, 11, 10) gets the next 10.

How do I split a string and remove empty cells?

If your string has multiple delimiters in a row (e.g., "Apple,,Banana"), TEXTSPLIT may create empty cells. You can wrap the function in FILTER: =FILTER(TEXTSPLIT(A2, ","), TEXTSPLIT(A2, ",") <> "").

Does TEXTSPLIT work in Excel 2016 or 2019?

No, TEXTSPLIT is only available in Microsoft 365 and Excel 2021. Users of older versions must use the "Text to Columns" feature or the LEFT/MID/RIGHT function combinations.

How can I split a string based on a line break?

To split text that is separated by a new line (Alt+Enter), use the CHAR function for the delimiter. In Windows, a line break is character 10. Use: =TEXTSPLIT(A2, CHAR(10)).

Can I split a string into a specific number of columns only?

TEXTSPLIT will split every instance of the delimiter it finds. If you only want the first two parts, you can wrap the formula in the TAKE function: =TAKE(TEXTSPLIT(A2, ","), , 2), which limits the output to the first two columns.