FormulaCraft

How to calculate standard deviation in Excel and Google Sheets

Topic:RANK & statistical aggregates

Heads up: Excel and Google Sheets do this differently.

Excel
=STDEV.S(B2:B6)
Google Sheets
=STDEV(B2:B6)

Verified example

Computed by a real spreadsheet engine on the sample data below.

TestResult
Trial 145
Trial 252
Trial 349
Trial 455
Trial 548

=STDEV.S(B2:B6)3.8340579025

Try it with your data

Edit the grid or formula, then run it through a real spreadsheet engine — no signup.

Sample data — click any cell to edit

Runs server-side · free · no signup

Step by step

  1. 1Select the output cell.
  2. 2In Excel, type =STDEV.S(B2:B6) for a sample standard deviation.
  3. 3In Google Sheets, type =STDEV(B2:B6) — it calculates sample standard deviation by default.
  4. 4For population standard deviation: Excel uses =STDEV.P(B2:B6); Google Sheets uses =STDEVP(B2:B6).
  5. 5Press Enter.

Tips

Need it for your exact data?

Describe your columns in plain English and get the precise formula for your sheet, with the right Excel or Sheets syntax.

Frequently asked

When should I use STDEV.S versus STDEV.P?

Use STDEV.S when your data is a sample drawn from a larger population (most real-world scenarios). Use STDEV.P only when you have data for the entire population.

Why are Excel and Google Sheets function names different?

Excel introduced STDEV.S and STDEV.P in 2010 for clarity. Google Sheets retained the older names STDEV and STDEVP. Both compute the same formulas.

More on RANK & statistical aggregates

See all →

Formulas used

Written and reviewed by FormulaCraft Team. Each formula on this page is run through our verification engine before publishing.

Last reviewed: