Standard deviation measures how spread out a set of numbers is from their average. To find it, you follow five steps: calculate the mean, subtract the mean from each data point, square those differences, average the squared differences, and take the square root. Let’s walk through the full process with real numbers.
The Five Steps, Explained
Here’s the process using a small dataset: 6, 2, 3, 1.
Step 1: Find the mean. Add all the values and divide by how many there are. (6 + 2 + 3 + 1) ÷ 4 = 12 ÷ 4 = 3. The mean is 3.
Step 2: Subtract the mean from each value, then square the result. Squaring removes negative signs and gives extra weight to values that are far from the mean.
- 6 minus 3 = 3, squared = 9
- 2 minus 3 = -1, squared = 1
- 3 minus 3 = 0, squared = 0
- 1 minus 3 = -2, squared = 4
Step 3: Add up all the squared differences. 9 + 1 + 0 + 4 = 14.
Step 4: Divide by the number of data points. 14 ÷ 4 = 3.5. This result is called the variance.
Step 5: Take the square root. The square root of 3.5 is approximately 1.87. That’s your standard deviation.
The standard deviation of 1.87 tells you that, on average, each value in the dataset sits about 1.87 units away from the mean of 3.
A Larger Example With Heights
To see how this works with a bigger dataset, consider nine students whose heights in inches are: 56, 65, 74, 75, 76, 77, 80, 81, and 91. The mean height is 75 inches.
Subtracting the mean from each height and squaring gives you:
- 56: (-19)² = 361
- 65: (-10)² = 100
- 74: (-1)² = 1
- 75: (0)² = 0
- 76: (1)² = 1
- 77: (2)² = 4
- 80: (5)² = 25
- 81: (6)² = 36
- 91: (16)² = 256
The sum of those squared differences is 784. Divide by 9 to get a variance of 87.1, and take the square root to get a standard deviation of 9.3 inches. That means the typical student’s height falls about 9.3 inches above or below the class average of 75 inches.
Population vs. Sample: When to Use N-1
The examples above divide by N, the total number of data points. That gives you the population standard deviation, which you use when your dataset includes every member of the group you care about (all students in a class, all products in a shipment).
If your data is a sample pulled from a larger group, you divide by N-1 instead of N. This small adjustment corrects for the fact that a sample tends to underestimate the true spread of the full population. In the height example, dividing 784 by 8 instead of 9 would give a slightly larger variance of 98, and a standard deviation of about 9.9 inches. The smaller your sample, the more this correction matters.
Variance vs. Standard Deviation
Variance and standard deviation both measure spread, but they differ in one important way. Variance is expressed in squared units (squared inches, squared dollars), which makes it hard to interpret directly. Standard deviation is simply the square root of variance, so it’s back in the same units as your original data. If you’re measuring heights in inches, your standard deviation is also in inches. That’s why standard deviation is almost always more useful for real-world interpretation.
What Your Result Actually Tells You
A low standard deviation means the values cluster tightly around the mean. A high standard deviation means they’re spread far apart. Two classrooms could both have an average test score of 80, but one might have a standard deviation of 3 (nearly everyone scored between 77 and 83) while the other has a standard deviation of 15 (scores ranged widely from the 60s to the high 90s).
For data that follows a bell curve (normal distribution), the 68-95-99.7 rule gives you a quick way to interpret standard deviation. About 68% of values fall within one standard deviation of the mean. About 95% fall within two standard deviations. And 99.7% fall within three. In the height example, one standard deviation from the mean covers 75 ± 9.3 inches (roughly 66 to 84 inches), which captures about 68% of the class.
In finance, standard deviation is used to measure how volatile an investment is. A stock with a high standard deviation swings dramatically in price. A stable index fund typically has a low standard deviation, meaning its returns stay close to the average. When you see “risk” quantified on an investment profile, standard deviation is often the number behind it.
Calculating Standard Deviation in Spreadsheets
You don’t need to do this by hand every time. Excel and Google Sheets have built-in functions that handle the entire calculation in one step.
- STDEV.S calculates the sample standard deviation (divides by N-1). Use this when your data represents a sample from a larger group.
- STDEV.P calculates the population standard deviation (divides by N). Use this when your data includes the entire group.
Type either function into a cell, select your data range, and the result appears instantly. For example, if your data is in cells A1 through A9, entering =STDEV.S(A1:A9) returns the sample standard deviation. The same functions work identically in Google Sheets.

