StatGardenREF. DESK
Calculators/Maths/Sum of digits
Maths

Sum of digits calculator

Adds up the individual digits of a whole number in one pass (not repeated to a single digit).

What this calculator does

Sum of digits works out adds up the individual digits of a whole number in one pass (not repeated to a single digit). Enter your own figures above and the answer updates as you type: nothing is fixed in the code, so the result reflects exactly the numbers you supply.

The formula this calculator evaluates is printed under the tool and explained below, so you can check the working by hand or reuse it in a spreadsheet.

The formula

FormulaFor n with digits d₁d₂…dₖ: sum = d₁ + d₂ + … + dₖ

The inputs explained

FieldWhat to enter
NumberA number. Starts at 48213.

Worked examples

Every figure in the tables below is produced by this page’s own calculator at build time, so the numbers and the tool always agree. Select any row to load that scenario.

How the answer changes with number

Every other input is held at the calculator’s starting values while number varies. Select any row to load that scenario into the calculator.

How the answer changes with number
NumberSum of digitsDigits usedNumber of digits
24,107142 + 4 + 1 + 0 + 7 = 145
36,160163 + 6 + 1 + 6 + 0 = 165
48,213184 + 8 + 2 + 1 + 3 = 185
72,320147 + 2 + 3 + 2 + 0 = 145
96,426279 + 6 + 4 + 2 + 6 = 275
144,639271 + 4 + 4 + 6 + 3 + 9 = 276