What VALUE does
VALUE turns text that looks like a number into a real number. =VALUE(B2) reads the text “1,250.00” in B2 and returns the number 1250, which SUM and lookups can work with. Text with a currency sign or a percent sign converts too, so “$2,045.50” becomes 2045.5 and “12%” becomes 0.12.
Numbers stored as text usually arrive in exports from other systems. They sit on the left of the cell, often with a small green triangle in the corner, and SUM skips them, so a total comes out too low or as 0. A lookup misses them as well, because the text “4052” and the number 4052 are different values to Excel.
Excel also converts text by itself when you calculate with it, so =B2*1 gives the same number as =VALUE(B2). VALUE makes the purpose of the formula plain to the next person who reads it.
Syntax
textRequired- The text to convert, usually a cell such as
B2. It can include a currency sign, thousands separators or a percent sign, as in"$1,250.00"or"12%". Text that Excel reads as a date or a time converts to the number behind it.
Example: amounts an export stored as text
A bank export puts the amounts in column B as text. SUM over them returns 0, and VALUE in column C turns each one into a number. The formula in C2 is filled down to C4.
Once column C is right, you can keep the numbers and drop the formulas: copy C2:C4, paste them over B2:B4 with Paste Values, then clear column C.
Example: a staff number that won’t look up
A badge scanner exports staff numbers as text, and the staff list holds them as numbers. Looking up the text “4052” finds nothing, so VALUE converts it inside the lookup.
When it’s the list that holds text and the value you look up that’s a number, turn the number into text instead: =XLOOKUP(B6&"",A2:A4,B2:B4).
Practice this in ProExcel
Look up a staff number the time clock exported as text, in a real practice sheet.
ProExcel checks your answer the moment you press Enter.
Other ways to convert text to numbers
A formula leaves the text where it is and puts the numbers in a new column. To convert the cells themselves:
- Select the cells, click the error button that appears beside them, and choose Convert to Number.
- Type 1 in an empty cell and copy it, select the text numbers, then choose Paste Special and Multiply. Each cell is multiplied by 1, which stores it as a number.
- For numbers written with a comma as the decimal point, such as 1.234,56, use NUMBERVALUE, which takes the decimal separator and the thousands separator as arguments:
=NUMBERVALUE(A2,",",".")returns 1234.56.
Common mistakes
=VALUE("n/a")shows#VALUE!. VALUE reads only text that Excel would accept as a number if you typed it. Clean out notes and letters first, or catch them with IFERROR.- A space inside the number, as in “1 250”, also gives
#VALUE!. Remove it with SUBSTITUTE first:=VALUE(SUBSTITUTE(A2," ",""))returns 1250. =VALUE("1.234,56")gives#VALUE!in Excel set up for the US, where the comma separates thousands. Use NUMBERVALUE with the separators spelled out.=VALUE(XLOOKUP(B6,A2:A4,B2:B4))converts the answer, and the lookup still searches for the text. Put VALUE around the value you look up:=XLOOKUP(VALUE(B6),A2:A4,B2:B4).
Frequently asked questions
How do I convert text to a number in Excel?
In a new column, use =VALUE(B2) and fill it down. To convert the cells themselves, select them, click the error button beside them and choose Convert to Number, or multiply them by 1 with Paste Special.
Why is my SUM formula returning 0?
The numbers are most likely stored as text, which SUM skips. They sit on the left of their cells. Convert them with VALUE or Convert to Number, and the total appears.
Why does VALUE return #VALUE!?
The text isn’t something Excel can read as a number: it holds letters, a space in the middle, or separators from another region, such as 1.234,56 in Excel set up for the US. Remove the extra characters with SUBSTITUTE, or use NUMBERVALUE for other separators.
How do I convert text to numbers without a formula?
Select the cells, click the error button that appears beside them and choose Convert to Number. Or copy a cell holding 1, select the text numbers and use Paste Special with Multiply.
What is the difference between VALUE and NUMBERVALUE?
VALUE reads numbers written the way your computer’s regional settings expect. NUMBERVALUE takes the decimal separator and the thousands separator as arguments, so it reads 1.234,56 in any Excel: =NUMBERVALUE(A2,",",".") returns 1234.56.