The TEXTJOIN Excel function is a Text formula that joins strings together with a delimiter. You can enter static text strings, a range of cells, and individual cell references to join. In this guide, we’re going to show you how to use the Excel TEXTJOIN function and also go over some tips and error handling methods.


Supported versions

  • Excel 2016 and later

Excel TEXTJOIN Function Syntax

TEXTJOIN(delimiter, ignore_empty, text1, [text2], …)


Arguments

delimiter A text or numeric value to be used as separators between text1,…
ignore_empty A Boolean value to determine whether empty cells are going to be ignored. If TRUE, empty cells will be ignored.
text1 String(s) to be joined.
[text2, …] Optional. More strings up to 252 that are joined together.


Example

The TEXTJOIN function essentially has 2 extra features in comparison to text merging through concatenating. First, TEXTJOIN allows adding delimiters between strings, and second, it can skip empty fields to prevent extra delimiters.

=TEXTJOIN(delimiter,ignore_empty,text)

The first row in this example combines the strings in range B4:F4 with a delimiter text " & ". If the argument ignore_empty is set to FALSE, you will see repeating delimiters like " &  & ". You can set it to TRUE to avoid this.

Download Workbook


Summary and Tips

  • If you do not need delimiters between strings, use the CONCAT function instead.
  • Like the CONCAT function, the TEXTJOIN is also a newer alternative to the CONCATENATE function.

Issues

  • If the return string exceeds the maximum allowed characters for a cell, the formula returns a #VALUE! error. The limit is 32,767 as of writing this article.