# Google Sheets SUMSQ Function: Syntax, Examples & Tips

- URL: https://betteranalyst.com/google-sheets/sumsq-function
- Author: Better Analyst

Formula Bot is now Better Analyst—same account, more powerful analysis.Formula Bot is now Better Analyst—same account and workflows, with more powerful analysis, dashboards, and automation.

[Learn what changed](https://betteranalyst.com/formula-bot-is-now-better-analyst)

Returns the sum of the squares of a series of numbers and/or cells.

```
=SUMSQ(value1, [value2, ...])
```

Generate FormulaExplain Formula

One free generation or explanation per browser, shared across Excel and Google Sheets. Account usage limits apply afterward.

Describe the SUMSQ you need in plain EnglishGenerate Formula

## Parameters

| Parameter | Required | Description |
| - | - | - |
| **value1** | Yes | The first number or range whose values will be squared and added. |
| **value2, ...** | No | Additional numbers or ranges to include. |

## What Is SUMSQ?

SUMSQ squares each number you give it and then adds those squares together. `=SUMSQ(3, 4)` returns 25, because 3² + 4² = 9 + 16. It accepts individual numbers, cell references and whole ranges, so `=SUMSQ(A2:A100)` squares and totals every value in the range in one step.

## How SUMSQ Works

For each numeric value in its arguments, SUMSQ multiplies the value by itself and adds the result to a running total. It is equivalent to:

```
=SUMPRODUCT(A2:A100, A2:A100)
```

or

```
=SUM(ARRAYFORMULA(A2:A100^2))
```

but shorter and clearer.

### How SUMSQ treats different values

- **Numbers in ranges** are squared and summed.
- **Blank cells and text inside a range** are ignored.
- **Numbers typed directly as arguments** are always included.
- **Negative numbers** become positive when squared, so `=SUMSQ(-3)` returns 9.

## Basic Examples

### Sum of squares of a few numbers

```
=SUMSQ(1, 2, 3)
```

Returns 14 (1 + 4 + 9).

### Sum of squares of a range

```
=SUMSQ(B2:B20)
```

### Multiple ranges

```
=SUMSQ(B2:B20, D2:D20)
```

Squares every number in both ranges and adds them all together.

### Length of a vector (Euclidean norm)

```
=SQRT(SUMSQ(B2:D2))
```

Returns the magnitude of a 3-dimensional vector stored in B2:D2 — for example, the straight-line distance from the origin.

### Distance between two points

```
=SQRT(SUMSQ(C2-A2, D2-B2))
```

With x1, y1 in A2:B2 and x2, y2 in C2:D2, this gives the distance between the points.

## Statistical Uses

The sum of squares is a building block of many statistics:

- **Root mean square (RMS)**: `=SQRT(SUMSQ(B2:B100)/COUNT(B2:B100))`
- **Sum of squared errors** between forecasts and actuals: `=SUMXMY2(B2:B100, C2:C100)` is the dedicated function, but SUMSQ works on a pre-computed error column.
- **Variance by hand**: the squared deviations from the mean can be totalled with DEVSQ, which is SUMSQ applied after subtracting the mean.

## Common Use Cases

- **Engineering and physics**: Vector magnitudes, RMS voltage or current.
- **Forecast accuracy**: Totalling squared residuals.
- **Geometry**: Pythagorean distances.
- **Data science**: Feature normalisation (L2 norm).

## Common Errors

- **Unexpectedly small result**: Numbers stored as text in a range are skipped silently. Convert them with VALUE or check with ISNUMBER.
- **#VALUE!**: A text value that cannot be read as a number was typed directly as an argument (for example `=SUMSQ("abc")`).
- **Confusing SUMSQ with SUM squared**: `=SUMSQ(2, 3)` is 13, while `=POW(SUM(2, 3), 2)` is 25. They are different calculations.
- **Error values in the range**: Any `#N/A` or `#DIV/0!` inside the range makes SUMSQ return that error. Clean the range or use IFERROR upstream.

## Tips and Best Practices

- Use DEVSQ when you want squared deviations from the mean rather than raw squares.
- Use SUMX2MY2, SUMX2PY2 and SUMXMY2 for paired-array variants.
- Pair SUMSQ with SQRT for magnitudes and distances.
- SUMSQ accepts up to many ranges at once, so there is no need to build helper columns of squared values.

## Related Functions

[POW](https://betteranalyst.com/google-sheets/pow-function), SQRT, SUMPRODUCT, DEVSQ, SUMXMY2, VAR, and STDEV.

## Example use case

An engineer logging AC voltage samples in column B needs the RMS value. The formula =SQRT(SUMSQ(B2:B501)/COUNT(B2:B501)) squares every sample, averages the squares and takes the square root, giving the effective voltage in a single cell.

## Need more help with Google Sheets formulas?

Sign up for Better Analyst and get unlimited AI-powered formula generation, explanations, and advanced data analysis.

[Create Free Account](https://betteranalyst.com/signup)[Try Formula Generator](https://betteranalyst.com/excel-ai)

## Google Sheets how-to guides

- [How To Copy Formula In Google Sheets](https://betteranalyst.com/google-sheets/how-to-copy-formula-in-google-sheets)
- [How To Count Unique Values In Google Sheets](https://betteranalyst.com/google-sheets/how-to-count-unique-values-in-google-sheets)
- [How To Create A Pivot Table In Google Sheets](https://betteranalyst.com/google-sheets/how-to-create-a-pivot-table-in-google-sheets)
- [How To Divide In Google Sheets](https://betteranalyst.com/google-sheets/how-to-divide-in-google-sheets)
- [How To Enable Macros In Google Sheets](https://betteranalyst.com/google-sheets/how-to-enable-macros-in-google-sheets)
- [How To Filter In Google Sheets](https://betteranalyst.com/google-sheets/how-to-filter-in-google-sheets)
- [How To Find Circular References In Google Sheets](https://betteranalyst.com/google-sheets/how-to-find-circular-references-in-google-sheets)
- [How To Find Duplicates In Google Sheets](https://betteranalyst.com/google-sheets/how-to-find-duplicates-in-google-sheets)

## Explore all Google Sheets formulas

Browse our complete library of Google Sheets formula guides

Compare your options

## Decide with evidence, not a sales pitch.

Open a neutral research prompt in the AI tool you already use. Compare capabilities, limitations, and fit before you choose.

1. [01ChatGPTOpen a balanced comparison prompt in ChatGPT.](https://chatgpt.com/?prompt=Compare%20Better%20Analyst%20with%20using%20a%20general-purpose%20AI%20assistant%20for%20data%20analysis.%20Evaluate%20spreadsheet%20and%20document%20analysis%2C%20dashboards%2C%20repeatable%20reports%2C%20code%20transparency%2C%20data%20connections%2C%20pricing%2C%20and%20limitations.%20Use%20current%20public%20sources%2C%20distinguish%20verified%20facts%20from%20assumptions%2C%20and%20explain%20which%20types%20of%20users%20each%20option%20fits%20best.)
2. [02ClaudeOpen the same research prompt in Claude.](https://claude.ai/new?q=Compare%20Better%20Analyst%20with%20using%20a%20general-purpose%20AI%20assistant%20for%20data%20analysis.%20Evaluate%20spreadsheet%20and%20document%20analysis%2C%20dashboards%2C%20repeatable%20reports%2C%20code%20transparency%2C%20data%20connections%2C%20pricing%2C%20and%20limitations.%20Use%20current%20public%20sources%2C%20distinguish%20verified%20facts%20from%20assumptions%2C%20and%20explain%20which%20types%20of%20users%20each%20option%20fits%20best.)
3. [03PerplexityResearch the comparison with linked web sources.](https://www.perplexity.ai/search?q=Compare%20Better%20Analyst%20with%20using%20a%20general-purpose%20AI%20assistant%20for%20data%20analysis.%20Evaluate%20spreadsheet%20and%20document%20analysis%2C%20dashboards%2C%20repeatable%20reports%2C%20code%20transparency%2C%20data%20connections%2C%20pricing%2C%20and%20limitations.%20Use%20current%20public%20sources%2C%20distinguish%20verified%20facts%20from%20assumptions%2C%20and%20explain%20which%20types%20of%20users%20each%20option%20fits%20best.)

AI answers can be incomplete. Check source links, current pricing, and product documentation before deciding.
