HomeExcel Functions ► Excel COLUMNS Function

Syntax For Excel COLUMNS Function

What is the use of Excel COLUMNS Function?

Use Excel COLUMNS Function to get the number of columns include in a reference or array. In simple words, you can get the number of columns which are included in the reference. For example for reference A1:D1 if will return 4, as a result, because you have 4 columns in that reference A, B, C & D

Syntax for Excel COLUMNS Function

COLUMNS(array)

array An array or range get from which you want to get the number of columns.

More Information on Excel COLUMNS Function

  • You can also use named range in columns function.
  • Columns function is not concerned with the values in the cells, it will simply return the number of columns in a reference.

Examples to understand Excel COLUMNS Function

Get Column Numbers With Excel COLUMNS Function

In above example, I have used columns function to get the number of columns from range A1:F1.

Create Header Serial Number With Excel COLUMNS Function

In above example, I have used columns function to create serial numbers in headers. I have used fixed cell reference for the first cell in the range & drag it to the left.

Download Sample File

Download Sample File To Learn Excel COLUMNS Function

More Tips Related With Excel COLUMNS Function

Conclusion

Use Excel COLUMNS Function to get the number of columns in a given range or an array. Learn more about COLUMNS from here.

Related Function

Column | Row | Rows

Excel Functions | Excel Formulas