SUM Function in ONLYOFFICE Spreadsheet Editor: Examples and Syntax
SUM in ONLYOFFICE Spreadsheet Editor: add numeric values across a range or multiple references with examples, advanced use, errors, troubleshooting and official sources.
Verification status: See the evidence and test scope described in this guide. How formula examples are checked
SUM adds numbers from one or more arguments. The five order amounts below total 70. Separate controls show how a shortened range, an omitted record or overlapping ranges changes that answer.
Availability and version history
- Introduced: The original introduction version and date are not established by the checked sources.
- Availability: Documented in the current ONLYOFFICE Spreadsheet Editor help; no final supported-version endpoint is established.
- Scope: Docs and Desktop Editors release separately. The unversioned help does not establish identical support in older builds, mobile clients or every deployment.
- Checked: October 14, 2026, against the official SUM reference and the cited implementation. Examples were independently calculated; these particular formulas have not been run in the native application.
Syntax and numeric inputs
SUM(number1, [number2], ...)
The official SUM entry shows one required argument and optional further arguments, with up to 255 numeric values in its description. A range can represent several observations; this is not a 255-cell worksheet limit. Brackets mark optional arguments and are not typed into these formulas. The examples use English names and comma separators; use the punctuation accepted by your locale.
For mixed data, the pinned official implementation distinguishes references from direct arguments. Its cell/range branch skips strings and logical values, while its direct-argument branch attempts numeric conversion. That source revision is not a claim about every installed Desktop or Docs build. Keep the main exercise numeric rather than assuming that a number-looking label is a number.
Build the five-order worksheet
Create OrderAmounts, leaving columns A:D and at least twelve rows available. Enter Order in A1 and Amount in B1, followed by:
| Row | A: Order | B: Amount |
|---|---|---|
| 2 | 101 | 12 |
| 3 | 102 | 15 |
| 4 | 103 | 30 |
| 5 | 104 | 8 |
| 6 | 105 | 5 |
Enter the amounts as numbers and put the following results in D. Do not replace any input while working through the table.
| Cell | Formula | Expected result |
|---|---|---|
| D2 | =SUM(B2:B6) |
70 |
| D3 | =SUM(B2:B4) |
57 |
| D4 | =SUM(B2:B4,B6) |
62 |
| D5 | =SUM(B5:B6) |
13 |
| D6 | =D3+D5 |
70 |
| D7 | =D6-D2 |
0 |
D3 uses 12+15+30. D4 includes those three records and the final amount of five, omitting the eight in B5. D6 instead partitions all five rows into two nonoverlapping groups and reconciles to the original total.
Advanced check: overlapping ranges count a record twice
On the same sheet, put =SUM(B4:B6) in D9 for 43, then =SUM(B2:B4,B4:B6) in D10 for 100. The selected groups overlap at B4. SUM does not know that the repeated 30 should represent one order.
In D11 enter =D10-B4 for 70, and in D12 enter =D11-D2 for 0. This correction is specific to the single shared cell. For more complex groups, identify their actual intersection instead of subtracting an arbitrary duplicate-looking value.
For a distinct signed-value exercise, copy OrderAmounts to RefundAmounts and change B4 from 30 to -30. D2 becomes 10 and D3 becomes -3. Replacing a positive 30 with a negative 30 lowers the total by 60, not 30. Use a negative amount only when it correctly represents the business event.
Reconstruct the vendor illustration
Create VendorSum and enter the following numbers in A1:B3:
| Row | A | B |
|---|---|---|
| 1 | 145 | 37 |
| 2 | 236 | 69 |
| 3 | 567 | 92 |
In D1 enter =SUM(A1:B3) for 1146, matching the official illustration. Column A totals 948 and B totals 198. Their sum is another independent reconstruction of the displayed result.
Stored text is a separate question
On a separate TypedSum sheet, enter numeric 3 in A2, ="5" in A3 and =TRUE() in A4. The pinned source’s reference-branch model predicts 3 for =SUM(A2:A4) in C2, because A3 is text and A4 is logical. This particular mixed-type example has not been run in the native application. It illustrates why display appearance cannot establish inclusion.
Do not change the original order amounts to reproduce this example. A text-producing formula and a true numeric amount should stay visibly separate in a teaching workbook.
Troubleshooting and related functions
- Total too large: Inspect overlapping ranges and accidentally selected subtotal cells.
- Total too small: Check the range endpoints and stored types. Formatting a text label as currency does not turn it into a number.
- A copied formula shifted: Use fixed references where the selected source range should remain unchanged.
- Errors or extreme inputs: These examples do not establish every error-propagation, overflow or imported-text rule.
Use SUMIF for one criterion and SUMIFS for several. PRODUCT multiplies factors; SUMPRODUCT adds corresponding products. Matching function names in another application do not establish identical input-conversion behavior.