Spreadsheet Practice

COLUMN function

COLUMN returns the column number of a cell: COLUMN(D1) is 4, and COLUMN() with nothing inside returns the column of the formula's own cell. Its most common job is supplying a changing column number to VLOOKUP or INDEX, so one formula can be filled across several columns.

Available in
Every current version
Category
Lookup functions
Returns
A column number, where column A is 1.
Google Sheets
Works the same way in Google Sheets.

Syntax

=COLUMN([reference])

ArgumentRequired?What it is
referenceOptionalThe cell to get the column number of. Leave it out to use the formula's own cell.

Examples

Each result below is calculated from the sample sheet by our formula engine, the same one that grades the practice.

CellFormulaResultWhat it shows
F2=COLUMN()6The formula is in column F, the sixth column
F3=COLUMN(D1)4D is the fourth column
F4=VLOOKUP("C-7",$A$2:$D$2,COLUMN(C1),FALSE)dana@example.comCOLUMN(C1) supplies 3, so VLOOKUP returns the email; filled right it becomes 4 and returns the phone

Try it live

This is the sample sheet. Change any number or text, or edit a formula, and the results update.

Show the sample data as a table
IDNameEmailPhoneResult
C-7Dana Leedana@example.com555-01426
4
dana@example.com

Practice COLUMN

Graded instantly, then re-checked on changed data.

One formula, three months

In B8, write one VLOOKUP that returns January units for the SKU in A8 and, filled right to D8, returns February and March. Use COLUMN to supply the column number.

Common mistakes

What you seeWhy, and how to fix it
Using COLUMN to count columnsCOLUMN returns a position, not a count. To count the columns in a range, use COLUMNS.
The number doesn't change when filled rightThe reference inside COLUMN is locked, as in COLUMN($B1). Leave the column unlocked so B1 becomes C1, then D1, as you fill.

Tips

  • MATCH on the header row is sturdier than COLUMN when the columns of a lookup table might be reordered.

Questions

How do I get the column number of a column letter?

Point COLUMN at any cell in that column: =COLUMN(H1) returns 8.

What does COLUMN() return with no argument?

The column number of the cell that contains the formula, so in column C it returns 3.

Last reviewed October 2026. Every example result on this page is calculated live by the Spreadsheet Practice formula engine.