← All how-to recipes

How to sum non-adjacent cells and ranges

✓ Verified in LibreOffice 25.8.7.3 ✓ Verified in Google Sheets (2026-08-30)

One total from scattered cells — separate blocks, specific columns, odd corners.

The formula

AppFormulaNotes
Excel (desktop)=SUM(A2:A10,C2:C10,E15)SUM takes up to 255 arguments — ranges and single cells mix freely.
Google Sheets=SUM(A2:A10,C2:C10,E15)Identical.
LibreOffice Calc=SUM(A2:A10,C2:C10,E15)Identical.

How it works

SUM's arguments are a list — each can be a range or a lone cell, and they don't need to touch: 30 + 20 + 50 = 100 here. Ctrl+clicking cells while typing the formula builds the list for you. Watch one trap: overlapping ranges double-count (SUM(A2:A10,A5:A15) counts A5:A10 twice), and if the scattered cells share a meaning, a status column plus SUMIF usually ages better than hard-coded addresses.

Verified, not just documented

We ran =SUM(A2:A3,C2:C3,E5) in LibreOffice 25.8.7.3 (headless, with forced recalculation) and it returned 100 — exactly the expected result. We then ran the same formulas in Google Sheets, executed 2026-08-30: a formula-only workbook goes into Google Drive, which converts it to a Sheet and recalculates every formula with Google’s own engine, and comes back out as .xlsx carrying the values Google computed. It returned 100 for the worked example, the same value LibreOffice produced. Both engines’ numbers on this page are executed results. The Excel formula follows Microsoft’s official documented syntax — we do not run desktop Excel.

Functions used

SUM — see full Excel, Google Sheets & LibreOffice compatibility for each.

Related recipes

Related comparisons