Excel Text Join Range: How to Combine Cell Values

How-to basics · Updated November 18, 2026

To join the text in an Excel range, use TEXTJOIN: with values in A2:A5, for example, enter =TEXTJOIN(", ",TRUE,A2:A5). It combines the cells with a comma and a space between items, while TRUE tells Excel to skip empty cells.

What Excel text join range means

Excel’s function for joining text is named TEXTJOIN—one word, with no space. A range is a group of cells, such as A2:A5 or B2:D4. In the formula, you can pass the range directly rather than building a long expression that refers to every cell individually.

This is useful when you need to turn a list of separate cell values into one text string: names for an email, tags for a record, a comma-separated list of products, or a sentence assembled from fields. The result is text in a single cell; TEXTJOIN does not combine or merge the source cells themselves.

TEXTJOIN is available in Excel 2019 and later, including Microsoft 365. In Microsoft 365 for Windows, type the formula in the cell where you want the finished text and press Enter. The result updates when the referenced cells change.

Understand the TEXTJOIN arguments

The function’s general structure is TEXTJOIN(delimiter, ignore_empty, text1, [text2], …). The first argument is the text to put between items, the second determines how empty entries are treated, and the remaining arguments contain the values or ranges to join. You can supply a range as one argument.

  • Delimiter: A character or sequence inserted between joined items, such as a comma, space, slash, or line break. Use an empty string, "", if you want no separator.
  • ignore_empty: TRUE skips empty cells; FALSE keeps their positions, which can produce repeated delimiters.
  • text1 and later text arguments: One or more cell references, ranges, or text values. TEXTJOIN places the delimiter between the resulting items, not after the final item.

In English-language Excel, formula arguments are separated by commas. Some regional settings use semicolons instead, so Excel may display or require a different argument separator on your computer. That setting is separate from the comma or other text you choose as the delimiter.

Join a range with a delimiter

Suppose A2:A5 contains Ava, Ben, an empty cell, and Kai. With those names in A2:A5, the formula =TEXTJOIN(", ",TRUE,A2:A5) returns Ava, Ben, Kai. The comma followed by a space is inserted between the nonempty values, and no comma is added at the end.

Change the delimiter to suit the output. With names in A2:A5, =TEXTJOIN(" - ",TRUE,A2:A5) produces Ava - Ben - Kai. With the same layout, =TEXTJOIN("",TRUE,A2:A5) produces AvaBenKai. An empty delimiter is useful for joining fragments of text, but it can make separate words or numbers difficult to distinguish.

You can also refer to a cell containing the delimiter, which makes it easy to change the separator without editing the formula. If D1 contains a comma and a space, and the values to combine are in A2:A5, use =TEXTJOIN($D$1,TRUE,A2:A5). The dollar signs keep the delimiter reference fixed if you copy the formula to another cell.

Decide how empty cells should behave

Choose TRUE when blanks should not appear to create missing list items. For example, a list with values in A2, A3, and A5 but a blank A4 will join as three values, with one delimiter between each. This is generally the expected result when creating a readable list from a column that may not be completely filled in.

FALSE is useful when the position of an empty cell matters. With values in A2:A4 where A3 is blank, =TEXTJOIN(", ",FALSE,A2:A4) includes the blank position, so the result has two delimiters next to each other. That may be appropriate when empty entries represent missing fields in a fixed sequence, but it usually looks untidy in a sentence.

A cell that looks blank is not always empty. A formula that returns an empty string may be skipped when ignore_empty is TRUE, but a cell containing spaces has text in it and is not treated as empty. If unexpected gaps remain, check for spaces or other invisible characters in the source values. You may need to clean the source data before joining it.

Combine separate ranges or add conditions

TEXTJOIN can take more than one range, including ranges that are not next to each other. If A2:A4 contains first names and C2:C4 contains last names, =TEXTJOIN(", ",TRUE,A2:A4,C2:C4) joins all the values from the first range and then the values from the second range. It does not pair each first name with the last name on the same row; it treats the arguments as a sequence of items to append.

To make one full name per row, join the two cells on each row instead, or create a helper column with each completed name and then join that column. This distinction matters: passing two ranges does not tell TEXTJOIN to match values by row or combine corresponding cells into pairs.

TEXTJOIN itself does not select values based on a condition. In Microsoft 365 or Excel 2021, you can combine it with FILTER to join only rows that meet a test. If A2:A10 contains names and B2:B10 contains status labels, use =TEXTJOIN(", ",TRUE,FILTER(A2:A10,B2:B10="Open","")) to return the names whose status is Open. FILTER supplies the matching names; the empty-string option gives TEXTJOIN an empty result if there are no matches.

Keep dates and numbers readable

TEXTJOIN can join numbers as well as text, but it does not necessarily preserve the way a number is displayed in its source cell. A date may be represented internally by a number, and a numeric ID formatted with leading zeros may lose those zeros when converted into text. If the appearance matters, explicitly format the value as text before joining.

For example, if A2:A4 contains dates and you want month, day, and year, Microsoft 365 users can format the values inside the join. With dates in A2:A4, =TEXTJOIN(", ",TRUE,TEXT(A2:A4,"mmm d, yyyy")) returns a comma-separated list such as Jan 5, 2026, Feb 12, 2026, Mar 3, 2026. The exact displayed date depends on the source dates and regional settings.

For numeric codes, TEXT can apply a number format before the values are joined. With numeric codes in A2:A4 that should display as five digits, use =TEXTJOIN(", ",TRUE,TEXT(A2:A4,"00000")). A value of 27 will then appear as 00027 in the joined result. These array-style TEXT examples are suited to Microsoft 365; in older Excel versions, a helper column that formats each value may be a clearer approach.

Common problems and practical limits

  • The formula shows #NAME?: Check that the function is spelled TEXTJOIN and that your Excel version supports it. The function is available in Excel 2019 and later.
  • The result has extra separators: Confirm that the second argument is TRUE if blank cells should be ignored. Look for cells containing spaces, which are not empty.
  • Dates or codes look different: Apply a text format with TEXT, or prepare the values in a helper column before joining.
  • The formula returns an error: Check whether any source cell contains an error value. Errors in the input can affect the result, so inspect the source cells instead of masking a problem without understanding it.
  • The result is too long: An Excel cell can contain at most 32,767 characters. A joined result that exceeds the cell’s text limit cannot be stored as an ordinary cell value.

It is also worth checking that the output cell is wide enough to read. A long result may appear cut off because neighboring cells contain data, even when the entire text is still stored in the cell. Select the result cell and inspect the formula bar to distinguish a display issue from a truncated value.

TEXTJOIN compared with other ways to combine text

The main advantage of TEXTJOIN over the ampersand operator is that it handles a whole range and applies one delimiter consistently. For two cells, an expression such as =A2&" "&B2 can be straightforward. For dozens of cells, repeating references and separators becomes cumbersome, and empty cells need extra handling.

CONCAT can combine text and ranges, but it does not provide TEXTJOIN’s delimiter and ignore-empty arguments. CONCATENATE is an older function and is also less convenient for joining a range with a repeated separator. Use TEXTJOIN when the job is specifically to turn multiple values into a delimited text string; use a simple ampersand expression when only a couple of pieces need to be combined in a custom pattern.

Remember that joining is different from merging cells. A joined result is a text value that can be copied, searched, or used in another formula. Merging cells changes the worksheet layout and does not assemble all their contents into a list. Keep the original data in separate cells if you still need to sort, filter, or analyze each item individually.

Frequently Asked Questions

Can TEXTJOIN join an entire column?
Yes. You can pass a column reference such as A:A as a range, but joining a very large range may be slower than using a practical data range. If you know the data occupies A2:A500, using that range makes the formula’s scope clear.

Does TEXTJOIN add a delimiter at the end?
No. It places the delimiter between items, not after the last item. With comma-and-space as the delimiter, the result is a clean list without a trailing comma.

Can TEXTJOIN join cells from different worksheets?
Yes. A range on another sheet can be referenced in the formula, such as Sheet2!A2:A5. If the sheet name contains spaces, surround it with single quotation marks, as in 'Sales Data'!A2:A5.

Why does TEXTJOIN leave a gap for a blank-looking cell?
The cell may contain a space or another character rather than being truly empty. TRUE skips empty entries, but it does not automatically remove all whitespace from the contents. Clean the source values if necessary.

Can I use a line break instead of a comma?
Yes. On Windows, CHAR(10) represents a line break, so it can be used as TEXTJOIN’s delimiter. Turn on Wrap Text for the result cell so the lines are visible. Mac and Windows both support this formula approach, though the cell’s display settings may affect how the result appears.

Related

Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.

More in How-to basics

Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources

Spotted an error in this guide? Let us know.