Find the number of any spreadsheet column (A = 1, Z = 26, AA = 27, XFD = 16,384) or turn a column number back into letters. Paste a list to convert many at once. Works for Excel, Google Sheets, LibreOffice and code that uses column indexes.
Last updated:
Convert
e.g. A, Z, AA, XFD, or a cell reference like $BC$12
Mix freely: letters become numbers, numbers become letters
Enter your values to see the result.
Advertisement
Advertisement
How to use the Excel Column Letter to Number Converter
Pick a direction: Letters → number, Number → letters, or Batch list.
Type the column, for example AA, or a number such as 703.
Press Convert to see the result, the working and the neighboring columns.
For many columns, choose Batch list, paste one item per line and download the results as CSV.
How spreadsheet column letters work
Column labels count like an odometer that uses the 26 letters as digits: A to Z, then AA to AZ, BA to BZ … ZZ, then AAA. Unlike ordinary base 26 there is no zero digit, so A stands for 1 and Z for 26. Mathematicians call this bijective base-26.
Letters → number: n = 0; for each letter from left to right, n = n × 26 + (letter position). Example AB: A = 1 → 1; 1 × 26 + 2 = 28.
Number → letters: while n > 0: r = (n − 1) mod 26, add letter r (0 = A), n = (n − 1) div 26. Read the letters in reverse.
Counting columns by length: 1 letter = 26 columns, 2 letters = 676 more (up to ZZ = 702), 3 letters = 17,576 more (up to ZZZ = 18,278).
Column letter to number reference
Letters
Number
Letters
Number
Letters
Number
A
1
AA
27
BA
53
E
5
AE
31
CA
79
J
10
AJ
36
DA
105
O
15
AO
41
IV
256 (old Excel limit)
T
20
AT
46
ZZ
702
Y
25
AY
51
AAA
703
Z
26
AZ
52
XFD
16,384 (Excel limit)
Tips for spreadsheets and code
In Excel or Google Sheets, =COLUMN() returns the number of the current column and =COLUMN(D1) the number of column D.
Programming libraries (for example pandas, openpyxl or Apache POI) often use zero-based indexes, where column A is 0. The converter shows that value too.
VLOOKUP and INDEX take a column number relative to the range, not the sheet. If your range starts at column C, column E is index 3 inside it.
Cell references like $AB$12 are accepted: the dollar signs and row number are ignored for the column calculation.
Frequently asked questions
What number is column AA in Excel?
Column AA is column 27. Z is 26, so the next column starts the two-letter sequence: AA = 27, AB = 28, AZ = 52, BA = 53.
How do you convert a column letter to a number?
Read the letters as a base-26 number where A = 1 and Z = 26. For each letter, multiply the running total by 26 and add the letter's value. For example XFD: X = 24; 24 × 26 + 6 (F) = 630; 630 × 26 + 4 (D) = 16,384.
How do you convert a column number to letters?
Subtract 1, divide by 26 and note the remainder (0 = A … 25 = Z). Repeat with the quotient until it reaches 0, then read the letters in reverse. For 28: (28 − 1) ÷ 26 = 1 remainder 1 → B; (1 − 1) ÷ 26 = 0 remainder 0 → A; so 28 = AB.
What is the last column in Excel?
Since Excel 2007, the last column is XFD, column 16,384. Older .xls files (Excel 2003 and earlier) stop at column IV, number 256.
How many columns does Google Sheets allow?
Google Sheets allows up to 18,278 columns, which ends at column ZZZ.
Why is it called bijective base-26?
Normal base 26 would need a zero digit. Spreadsheet columns have no zero: the digits run from A = 1 to Z = 26, and every number has exactly one spelling. That is called bijective numeration.
Is there an Excel formula for this?
Yes. =COLUMN(INDIRECT("AA1")) returns 27, and =SUBSTITUTE(ADDRESS(1,27,4),"1","") returns AA. This tool gives the same answers without opening a spreadsheet.
Are all the tools on FreeToolCabin tested for quality and accuracy?
Yes! Every tool on our site undergoes automated Q/A testing in real browser environments to ensure high precision, correct output, and zero errors. If you happen to spot a bug or have a suggestion, please contact us at [email protected] and our team will review it right away.