Author: Oscar Cronquist Article last updated on March 29, 2018

The COLUMNS function allows you to calculate the number of columns in a cell range.

The example above shows that cell range C2:J2 has 8 columns.

Excel Function Syntax

COLUMNS(array)

Arguments

array Required. A cell range for which you want to determine the number of columns.

Comments

The COLUMNS function also calculates the number of rows in an array.

=COLUMNS({1,2,3;4,5,6;2,3,4}) returns 3.

The array has three columns. The , (comma) character is a column delimiting character in an array.