Median Calculator

Find the median (middle value) of any dataset. Works with both even and odd numbers of data points.

MEDIAN
--
Count
--
Mean
--
Min
--
Max
--

What Is the Median?

The median is the middle value in a sorted dataset. It divides the data into two equal halves: 50% of values are below the median and 50% are above. It is a robust measure of central tendency that is not affected by extreme values (outliers).

The median is particularly useful when data is skewed or contains outliers. For example, median household income is typically reported instead of mean income because extreme earners would skew the average upward.

How to Find the Median

Odd n: Median = value at position (n+1)/2
Even n: Median = average of values at positions n/2 and n/2+1
  1. Sort the data from smallest to largest.
  2. If the count is odd, the median is the middle value.
  3. If the count is even, the median is the average of the two middle values.

Examples

DataSortedMedian
5, 1, 31, 3, 53
8, 2, 6, 42, 4, 6, 85 (avg of 4, 6)
10, 20, 30, 40, 5010, 20, 30, 40, 5030

Frequently Asked Questions

When should I use the median instead of the mean?

Use the median when your data is skewed, has outliers, or when you want a value that better represents the typical data point. Income, house prices, and response times are commonly reported as medians.

Can the median be a value not in the dataset?

Yes, when the dataset has an even number of values, the median is the average of the two middle values, which may not appear in the original data. For example, the median of {2, 4, 6, 8} is 5.

Is the median always between the mean and mode?

In unimodal, moderately skewed distributions, the median typically falls between the mean and mode. However, this is not a strict mathematical rule and exceptions exist for heavily skewed or multimodal distributions.