Fix Excel Sum Returning Zero: Convert Text to Numbers
Question details
The user is trying to sum a range of cells, but the calculation unexpectedly returns a total of zero instead of the actual sum.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- Calculating sums of imported or copied data that visually appears numeric but is formatted or stored incorrectly.
- Observed behavior
- The SUM function returns zero because the referenced numbers contain hidden spaces, unrecognized currency symbols, or are stored as text rather than numeric values.
Click on one of the problem cells and check the formula bar to see if there are leading spaces, trailing spaces, or unrecognized characters hidden inside the data.
Remove Hidden Spaces and Convert Text to Numbers
Clean the data by removing unwanted whitespace and forcing the spreadsheet to recognize the text strings as calculating numbers.
When data is imported from external databases or webpages, numbers are often stored as text or include hidden spaces. Mathematical functions like SUM will ignore these text values, resulting in a zero total.
Select an empty cell next to your data and enter the formula =VALUE(TRIM(A2)) (assuming A2 is your target cell). This removes standard spaces and converts the text to a number.
If you are using a newer version of Excel that supports Regular Expressions, you can use the formula =1*(REGEXREPLACE(A2,"\s+","")) to strictly strip all whitespace.
Press Enter, then click and drag the fill handle down to apply the formula to the rest of the column.
Copy the new calculation results, right-click the original column, and select Paste Special > Values to replace the text with the newly formatted numbers.

Use the Text to Columns Feature
Use the built-in Text to Columns tool to quickly parse and convert a whole column of text-formatted numbers into standard numeric values without writing formulas.
Easily Fix Number Formatting Issues in WPS Spreadsheet
WPS Spreadsheet offers powerful data cleaning tools, intuitive error checking, and text-to-number features, allowing you to instantly fix sum calculation errors.
- 1. Open Your Spreadsheet: Launch WPS Spreadsheet and open the document containing the calculation errors.
- 2. Identify Text Numbers: Highlight the cells returning a zero sum. Look for a small green triangle in the top-left corner of the cells, which indicates numbers stored as text.
- 3. Convert Instantly: Click the yellow exclamation mark warning icon that appears next to the selected cells and choose 'Convert to Number'.
- 4. Recalculate Sum: Your SUM formula will now automatically update to display the correct total.

Frequently Asked Questions
Why does the ISNUMBER function return FALSE for numbers in my spreadsheet?
ISNUMBER checks the underlying data type, not the cell's appearance or formatting. If a cell contains the string '1234', the software treats it as text, so ISNUMBER returns FALSE even though it looks like a numeric value.
Can system regional settings affect how my numbers are summed?
Yes. If your system's regional settings use a comma as a decimal separator but your imported data uses a period (or vice versa), the spreadsheet application won't recognize the entries as valid numbers and will skip them during sum calculations.
How do I remove non-breaking spaces that the TRIM function ignores?
Non-breaking spaces (often character 160) frequently appear in data copied from web pages. You can use the SUBSTITUTE function to remove them by typing =VALUE(SUBSTITUTE(A2, CHAR(160), "")) which strips the space and converts the remaining text to a number.




