Column M is the 13th column in Microsoft Excel. This means that if you are using a formula that requires a numerical index for a column—such as VLOOKUP, HLOOKUP, or OFFSET—you should use the number 13 to reference column M. Understanding how to translate alphabetical column letters into numerical indices is essential for advanced data manipulation and formula building.
What You'll Need
- A computer with Microsoft Excel installed (any version).
- A basic understanding of how to enter formulas into a cell.
- A dataset or a blank worksheet to practice the indexing methods.
Step-by-Step
While you can manually count from A to M, there are several professional ways to determine the column number for M or any other column using Excel's built-in tools. Depending on your goal, choose one of the following methods.
Method 1: Manual Counting
- Open your Excel workbook.
- Locate the column headers at the top of the grid.
- Start at column A and count each letter sequentially: A(1), B(2), C(3), D(4), E(5), F(6), G(7), H(8), I(9), J(10), K(11), L(12), M(13).
- Confirm that M is the 13th letter of the alphabet.
Method 2: Using the COLUMN Function
The COLUMN function is the most reliable way to find the index of a cell without counting manually. This is particularly useful if you are working with very distant columns (like XFD) where counting is impractical.
- Click on any empty cell in your worksheet.
- Type the following formula:
=COLUMN(M1). - Press Enter.
- Excel will return the value 13, confirming that column M is the 13th column.
Method 3: Using the COLUMN Function for the Current Cell
If you are already working inside column M and want to verify its number for a formula you are writing, use this shortcut.
- Click on any cell located within column M.
- In a nearby empty cell, type
=COLUMN()(leaving the parentheses empty). - Press Enter.
- Because the formula is referencing the cell it is currently in, it will return 13.
Method 4: Applying the Number in a VLOOKUP Formula
The most common reason users ask "what number is M" is to complete a VLOOKUP. Here is how to apply the number 13 in a real-world scenario.
- Identify your lookup value (the piece of data you are searching for).
- Define your table array. For example, if your data starts in column A and ends in column M, your range is A:M.
- In the
col_index_numargument of the VLOOKUP formula, enter 13. - Example formula:
=VLOOKUP("SearchTerm", A:M, 13, FALSE). - This tells Excel to look for the term in column A and return the corresponding value from the 13th column (M).
Common Mistakes
When dealing with column indices, small errors can lead to #REF! or #VALUE! errors. Be mindful of these frequent pitfalls:
- Miscounting the Range: A common mistake is counting the column index based on the selection rather than the sheet. For example, if your VLOOKUP range starts at column C and you want to get data from column M, the index is not 13. It is 11 (C=1, D=2... M=11). The index number is always relative to the first column of the selected range, not the absolute column letter of the spreadsheet.
- Off-by-One Errors: Users often accidentally count the starting column as 0 instead of 1. In Excel, the first column of any range is always index 1.
- Confusion with Rows: Ensure you are using the COLUMN function and not the ROW function. Using
=ROW(M1)will return 1 (the row number), not 13 (the column number). - Hard-coding Indices: While entering "13" works, if you insert a new column between A and M later, column M becomes column N. Your formula will still look at the 13th column, which is now L, returning the wrong data.
Tips
To make your spreadsheets more robust and professional, consider these advanced techniques for handling column numbers:
- Use the MATCH Function: Instead of hard-coding the number 13, use
MATCHto find the column number dynamically. For example:=MATCH("ColumnHeaderName", A1:Z1, 0). This will search the first row for your header and return the number 13 automatically. If you move the column, the formula updates itself. - Switch to Tables: Convert your data range into an official Excel Table (Ctrl + T). Tables allow you to use structured references (like
[@[ColumnName]]) instead of column numbers, eliminating the need to know that M is 13. - R1C1 Reference Style: If you frequently work with numerical column indices, you can change Excel's view. Go to File > Options > Formulas and check "R1C1 reference style". This replaces letters (A, B, C) with numbers (1, 2, 3) in the headers, making it immediately obvious that M is 13.
- Keyboard Navigation: To quickly jump to column M, press Ctrl + G (Go To), type "M1", and press Enter.
Troubleshooting
If your formula is returning the wrong data or an error despite using the number 13, try these steps in order:
- Verify the Range Start: Check the first column of your range. If your range is
B:M, then M is the 12th column of that range, not the 13th. Adjust your index to 12. - Check for Hidden Columns: Hidden columns still count toward the index. If you have hidden column B, column M is still the 13th column. Do not skip hidden columns when counting.
- Look for Merged Cells: Merged cells in the header row can confuse the
MATCHfunction or your manual count. Unmerge cells to ensure each column has a distinct identity. - Check for #REF! Errors: If you see a #REF! error, it usually means your column index number (13) is larger than the number of columns in your selected range. For example, if your range is
A:L(12 columns), asking for the 13th column will trigger this error. Expand your range toA:M. - Validate Data Types: If the formula returns a 0 or an unexpected result, ensure that the data in column M is not formatted as text when you expect a number, or vice versa.
Frequently Asked Questions
Is column M always 13 in every version of Excel?
Yes. The alphabetical ordering of columns is a standard across all versions of Microsoft Excel, including Excel 365, Excel 2021, 2019, and Excel for the Web.
What happens after column Z?
After column Z (26), Excel continues with double letters: AA (27), AB (28), and so on. Once ZZ is reached, it moves to AAA.
Can I use the letter "M" instead of the number 13 in VLOOKUP?
No. The col_index_num argument in VLOOKUP specifically requires a numeric value. If you want to use the letter, you must use a different function like INDEX and MATCH.
How do I find the number of a column if it is very far to the right?
The fastest way is to use the =COLUMN() function. Click any cell in that column and enter the formula to get the exact index immediately without counting.
Does the column number change if I filter the data?
No. Filtering hides rows, but it does not change the position or the index number of the columns.
Why does my VLOOKUP return the wrong column when I use 13?
This usually happens because your table range does not start at column A. If your range starts at column B, the 13th column is actually column N. Always count from the first column of your selected range.