Excel Formatting in Millions: Display Large Numbers
In this article
You format Excel numbers in millions by applying a custom number format such as #,##0.0,,"M" to the cells. The two trailing commas divide the displayed value by one million, while the number stored in the cell stays exactly as it is. That means your formulas, totals and charts keep working with the real figure, but the sheet reads cleanly as 12.5M instead of 12,500,000. It takes about a minute per range and you never touch the underlying data.
What You'll Need
- Excel for Windows or Mac, or Excel for the web. The Custom number format dialog works on all of them, though the dialog looks slightly different in the browser version.
- A column of large numbers you want to display in millions.
- Nothing else. No add-ins, macros or extra software are required.
Step-by-Step
Menu labels and dialog wording can differ a little between Excel versions, platforms and regions, so look for the closest match if what you see is worded differently.
- Select the cells you want to change. Drag across the range, or click the column header to take the whole column. If the numbers live in a table, select just the value column so your labels stay as text.
- Open the Format Cells dialog. Press Ctrl+1 (Windows) or Cmd+1 (Mac). You can also right-click the selection and choose Format Cells, or use Home > Number and click the small launcher arrow in the corner of that group.
- Go to the Number tab and choose Custom at the bottom of the category list. The Type box becomes editable.
- Type the format code. Enter #,##0.0,,"M" and press OK. For a whole-number version use #,##0,,"M" so 12,500,000 shows as 13M rather than 12.5M.
- Check the result. Click one of the formatted cells and look at the formula bar. It should still show the full number, for example 12500000. If the formula bar also shows the shortened value, you have overwritten the data, not formatted it, so undo with Ctrl+Z.
- Apply the same format to related columns. Use the Format Painter (Home > Format Painter) to copy the format to other ranges, or repeat the custom code on each one. Keep the same number of decimal places across every column so comparisons stay honest.
- Format your chart axis if you have one. Right-click the axis, choose Format Axis, open the Number section, and enter the same custom code in the Format Code box. The axis labels will then read in millions too.
Common Mistakes
Deleting the zeros by hand. Typing 12.5 in place of 12,500,000 destroys the value. Every SUM, average and chart built on that column then returns a figure a million times too small. Always use a format, never an edit.
Using one comma instead of two. A single trailing comma divides by a thousand, the next by a million and the third by a billion. Two commas is the only correct count for millions, and a stray space between them breaks the code.
Forgetting the quotation marks around text. The letter M must sit in double quotes as "M". An unquoted letter can make Excel reject the format or add stray characters.
Formatting labels as well as numbers. If you select a whole table, years like 2024 become 0.0M. Apply the format only to the numeric value columns.
Mixing decimals across columns. One column showing 12.5M beside another showing 13M looks sloppy and hides the real gap in scale. Choose one decimal setting and apply it everywhere.
Tips
- Add a currency symbol without extra fuss: $"#,##0,,"M" shows $12.5M, keeping the symbol in front of the abbreviated figure.
- For negative values in accounting style, use #,##0.0,,"M";-#,##0.0,,"M" so losses show a proper minus sign.
- Store the format in a style if you use it often. Choose Home > Cell Styles > New Cell Style and include the number format, then apply it with one click later.
- Keep the raw numbers in a hidden helper column if someone downstream needs the exact value, and leave a note in the header such as "Sales (millions)" so readers know the unit.
- If the shortened figures are being exported or pasted elsewhere, remember the text reads 12.5M but the cell still holds 12500000. Anyone copying values will get the full number, which is usually what you want.
Troubleshooting
The format does nothing. The cells may hold text rather than numbers, often because they were pasted from another system. Select them and use Data > Text to Columns > Finish to force conversion, or check for a leading apostrophe in the formula bar.
Excel rejects the code. Custom codes are fussy about quoting. Delete the whole entry in the Type box and retype #,##0.0,,"M" in one go, making sure the commas are plain English commas and the quotes are straight, not curly.
The value shows as 0.0M. That usually means the cell contains zero, or the number is already small (for example 850,000 becomes 0.9M). It is working correctly; the scale is simply wrong for that row.
Chart labels stay long. Formatting the worksheet cells does not automatically change chart labels. Apply the custom code separately in Format Axis and in the data labels options.
You cannot open Format Cells. On a protected sheet the formatting option can be locked. Ask the sheet owner to unprotect it, or unprotect with your own password if you set it.
If that did not work, start over on a blank cell with a known number, apply the format there and confirm it displays as expected. Once it does, copy that cell's format to the real range with the Format Painter, which rules out a corrupted or half-edited code.
Frequently Asked Questions
Does formatting in millions change the underlying value?
No. The cell still stores the full number, which you can confirm in the formula bar. Formulas, totals and pivot tables all use the real figure.
What is the difference between one and two trailing commas?
Each comma divides the displayed value by a thousand. One comma shows thousands, two show millions, three show billions.
Can I show an M suffix without decimals?
Yes. Use #,##0,,"M" and 12,500,000 displays as 13M. Expect rounding, so choose decimals when precision matters.
How do I show values in millions with a currency symbol?
Put the symbol in quotes at the front: $"#,##0,,"M". The same idea works for any currency symbol.
Why does my pasted data ignore the format?
Pasting with formatting from another file can overwrite your custom code. Use Paste Values instead, which keeps your formatting intact.
Can I apply this to a PivotTable?
Yes. Right-click a value field, choose Value Field Settings > Number Format, and enter the same custom code there.