Mean, Median, Mode Calculator
Three ways to say what's typical in a data set. Here's the same list three ways.
- Sorted list shown
- Standard deviation too
- Updated Nov 2, 2026
- Data (sorted)2 4 4 4 5 5 7 9
- Mean: 40 ÷ 85
- Median: (4 + 5) ÷ 24.5
- Mode4
- Range: 9 − 27
Use this mean, median, mode calculator to describe any data set. Paste your numbers to get the mean, median, mode, and range, with the sorted list and the middle value highlighted. It also gives the sample and population standard deviation.
Definitions follow the NIST e-Handbook of Statistical Methods (Measures of Location). Each section below uses the sample data set 2, 4, 4, 4, 5, 5, 7, 9.
| Statistic | Result for 2, 4, 4, 4, 5, 5, 7, 9 | How |
|---|---|---|
| Mean | 5 | 40 ÷ 8 |
| Median | 4.5 | (4 + 5) ÷ 2 |
| Mode | 4 | Appears 3 times |
| Range | 7 | 9 − 2 |
| Standard deviation (population) | 2 | Divides by N |
| Standard deviation (sample) | 2.138 | Divides by N − 1 |
How to Find the Mean
Add all the values and divide by how many there are. The sum is 40 and there are 8 values, so the mean is 40 ÷ 8 = 5.
Mean = sum of values ÷ number of valuesIn statistics, the mean of a sample is written x̄ ("x-bar") and the mean of a whole population μ ("mu"). Both are calculated exactly the same way, so a sample mean and a population mean of the same numbers are equal. The N − 1 adjustment for samples applies only to the standard deviation, covered below.
The mean can be a value that isn't in the list, and it doesn't have to be a whole number: the mean of 1, 2, 2, and 4 is 9 ÷ 4 = 2.25.
How to Find the Median
Sort the values from smallest to largest and find the middle one.
- Odd number of values: the median is the middle value. For 3, 7, 8, it's 7.
- Even number of values: the median is the average of the two middle values. For 2, 4, 4, 4, 5, 5, 7, 9, it's (4 + 5) ÷ 2 = 4.5.
The calculator highlights the middle value or values in the sorted list.
How to Find the Mode
The mode is the value that appears most often. In the sample, 4 appears three times, more than any other value, so the mode is 4. As NIST notes, the mode isn't necessarily unique:
- Two or more modes: in 1, 1, 2, 2, 3, both 1 and 2 appear twice, so there are two modes.
- No mode: if every value appears once, as in 85, 90, 78, there's no mode.
How to Find the Range
Subtract the smallest value from the largest. For the sample, that's 9 − 2 = 7. The range shows how spread out the data is, but a single extreme value can make it large.
Which Average Should You Use?
The mean uses every value, so one extreme number can pull it far from the rest. Take home prices of $300,000, $320,000, $350,000, $360,000, and $2,000,000. The mean is $666,000, but the median is $350,000, which is much closer to what most of these homes cost.
- Use the mean when values are fairly balanced, such as test scores in a class.
- Use the median when a few values are much larger or smaller, such as incomes or home prices.
- Use the mode for the most common choice, such as shoe size or a survey answer.
When some values should count more than others, such as test categories or purchases of different sizes, use the weighted average calculator instead.
Sample vs. Population Standard Deviation
Standard deviation measures how far values typically sit from the mean. If your numbers are the whole group you care about, use the population figure, which divides by N. If they're a sample from a larger group, use the sample figure, which divides by N − 1, the convention NIST uses for the sample variance (Measures of Scale). For the sample data, the population standard deviation is 2 and the sample standard deviation is about 2.138. For every step, the variance, and z-scores, use the standard deviation calculator.
Frequently Asked Questions
What if there are two modes?
The data set is bimodal (with three or more modes, multimodal) and both values are modes. The calculator lists every value tied for the most appearances.
What if there is no mode?
If no value appears more than once, the data set has no mode. That's a normal result, not an error.
How do you find the median of an even set of numbers?
Sort the numbers and average the two in the middle. For 3, 7, 8, 12, the median is (7 + 8) ÷ 2 = 7.5.
What's the difference between mean and average?
Usually none: "average" in everyday speech means the arithmetic mean. For a simple average with each step shown, use the average calculator; if values count differently, use the weighted average calculator.