Hands-On Excel

Hands-On Excel Challenges Numbers stored as text

Numbers stored as text in Excel

A number stored as text looks like a number but sits on the left of its cell, and SUM skips it without a warning. Convert it inside the formula: =SUMPRODUCT(B2:B9*1) turns every cell into a number before adding.

CoreAbout 3 minutesFree, no sign-upBy Updated

Try it yourself

26 · Numbers stored as text · Core

Mistake hunt: numbers stored as text

These payments were pasted in from a bank export, and the total in B10 is too low: three amounts came in as text, and SUM skips text. The next export will do the same, so don't retype the amounts. Fix the formula in B10 so it adds up all eight.

Numbers sit on the right of a cell and text on the left: that's how you spot them. Multiplying text like "1250" by 1 gives the number 1250, and SUMPRODUCT(B2:B9*1) does that to every cell before adding.

payments.xlsx
Ready

Write in the green cells, then press Check. Click a cell while typing to insert it, drag to select a range, F4 adds $, Esc cancels.

The guide · Numbers stored as text

How to spot them

They usually come from somewhere else: a paste from a website, a bank or accounting export, a CSV file, or a cell formatted as Text before the number was typed.

Why SUM ignores them

SUM adds the numbers in a range and skips everything else: blanks, words, and text that happens to look like a number. The total is just lower. Plain arithmetic is different: =B2+B3 converts "1250" to 1250 on the way. That's why a long =B2+B3+… can disagree with SUM on the same cells.

Worked example

Eight payments, three of them pasted in as text: 1250, 85 and 530. =SUM(B2:B9) returns 1,835. The real total is 3,700, so SUM is 1,865 short: exactly the three text amounts.

Fix it in the formula

FormulaWorks in
=SUMPRODUCT(B2:B9*1)every version of Excel
=SUM(VALUE(B2:B9))Excel 365 and 2021 (older versions need Ctrl+Shift+Enter)
=SUM(--B2:B9)Excel 365 and 2021

Each one turns every cell into a number before adding. Multiplying by 1, VALUE, and the double minus all turn "1250" into 1250. Because the fix lives in the formula, the next import with the same problem is handled too.

Or fix the data

For a one-off clean-up, select the cells and choose Convert to Number from the warning, or use Data → Text to Columns → Finish. A helper column with =B2*1 or =VALUE(B2) works too. These fix the data once; the next paste brings the problem back.

Lookups have the same problem

The text "1001" and the number 1001 don't match, so VLOOKUP and MATCH return #N/A even though the value looks the same. The #N/A mistake hunt covers that case.

Common mistakes

FAQ

Why is my Excel SUM not adding up?
Some numbers are probably stored as text, and SUM skips them without a warning. Look for numbers that line up on the left, or compare =COUNT(range) with how many numbers you expect.
How do I convert numbers stored as text to numbers?
Inside a formula, multiply by 1, use VALUE, or put a double minus in front. In the data itself, select the cells and use Convert to Number, or Data → Text to Columns → Finish.
How do I sum numbers stored as text in Excel?
=SUMPRODUCT(B2:B9*1) works in every version. In Excel 365 and 2021, =SUM(VALUE(B2:B9)) works too.
Why doesn't formatting the cells as Number fix it?
A format changes how a value is shown, not what is stored. Text stays text until it is converted, for example with Text to Columns or by entering it again.

All challenges

  1. 01 Add it upSUM Starter · 3 min
  2. 02 Find the averageAVERAGE Starter · 3 min
  3. 03 Write once, fill downRelative references Starter · 3 min
  4. 04 Lock it with $Absolute references Core · 3 min
  5. 05 Lock just the row or the columnMixed references Advanced · 3 min
  6. 06 Percent of a totalPercentages Starter · 3 min
  7. 07 Up or down by how much?Percent change Core · 3 min
  8. 08 Select to the end in one moveCtrl + Shift + arrow Core · 3 min
  9. 09 Pass or fail?IF Core · 3 min
  10. 10 Both or either?AND, OR Core · 3 min
  11. 11 Grade bands with nested IFNested IF Core · 3 min
  12. 12 Count the ones that matchCOUNTIF Core · 3 min
  13. 13 Add up the ones that matchSUMIF Core · 3 min
  14. 14 Use a cell as the conditionCriteria in a cell Core · 3 min
  15. 15 Count with two conditionsCOUNTIFS Core · 3 min
  16. 16 Add up with two conditionsSUMIFS Core · 3 min
  17. 17 Look it upVLOOKUP Core · 3 min
  18. 18 Find the right bracketVLOOKUP approximate match Core · 3 min
  19. 19 XLOOKUP, the modern wayXLOOKUP Core · 3 min
  20. 20 Where is it in the list?MATCH Core · 3 min
  21. 21 INDEX and MATCH togetherINDEX + MATCH Advanced · 3 min
  22. 22 Catch the error, not the bugIFERROR Core · 3 min
  23. 23 Split first and last namesLEFT, MID + FIND Core · 3 min
  24. 24 Mistake hunt: #N/A everywhereFixing #N/A Core · 3 min
  25. 25 Mistake hunt: hard-coded numbersReferences instead of typed numbers Core · 3 min
  26. 26 Mistake hunt: numbers stored as textNumbers stored as text Core · 3 min

Pro · coming soon

From first formula to job-ready.

100+ challenges on lookups, pivot tables, dates and text cleanup, an interview track modeled on the Excel tests employers use, and your progress saved across devices.

$29 one-time · early-bird price

You won't be charged today.

You're early!

Pro isn't open yet. We're building it right now. Leave your email and we'll hold the $29 early-bird price for you and tell you the day it launches.

We'll email you a link to confirm, then one email when Pro launches. Privacy