Median Calculator

Share calculator:
Embed this tool:

Enter your numbers, separated by commas, spaces or new lines, and press the button to find the median: the value that splits the sorted list into a lower half and an upper half.

What is the median?

The median is the middle value of a data set once the values are arranged from smallest to largest. Half of the observations are at or below it and half are at or above it, which is why it is also called the 50th percentile.

Unlike the mean, the median does not react to how large the extreme values are, only to where they fall in the order. That makes it a dependable summary for data with a long tail, such as incomes, property prices or the time people wait for a bus.

How to find the median

  1. Sort the numbers from smallest to largest.
  2. Count them. Call the count n.
  3. If n is odd, the median is the value in position (n + 1) ÷ 2.
  4. If n is even, average the values in positions n ÷ 2 and n ÷ 2 + 1.

median = (x[n/2] + x[n/2 + 1]) ÷ 2For an even count n, where x[k] is the k-th value of the sorted list.

Example with an odd count

Five customers waited 17, 4, 9, 23 and 11 minutes. Sorted, the list is 4, 9, 11, 17, 23. There are five values, so the median sits in position (5 + 1) ÷ 2 = 3: the median wait is 11 minutes.

Example with an even count

A walker logged 6.2, 8.1, 7.4, 9.0, 5.5 and 10.3 thousand steps over six days. Sorted: 5.5, 6.2, 7.4, 8.1, 9.0, 10.3. The middle pair is 7.4 and 8.1, and (7.4 + 8.1) ÷ 2 = 7.75 thousand steps. Note that 7.75 is not one of the recorded days, which is normal for an even count.

Using this calculator

Type or paste the numbers into the box. Commas, spaces, tabs and new lines all work as separators, negatives and decimals are fine, and you do not need to sort anything. The result has two rows: the Median and the Count of numbers, so you can confirm that every value was picked up.

  • A whole-number result is shown bare. A result with one or two decimals is shown with two (for example 1.50), and a longer one is rounded to four decimals.
  • Anything that is not a number is read as zero and counted, so check your list for stray words or typos.
  • A semicolon is not a separator. Use commas, spaces or new lines.

Median versus mean

The two measures agree when data is symmetric and diverge when it is skewed. Take seven yearly salaries: 32,000, 35,000, 36,000, 38,000, 41,000, 44,000 and 250,000. Their sum is 476,000, so the mean is 476,000 ÷ 7 = 68,000. The median is the fourth value, 38,000. Only one person earns more than the mean, so it describes nobody in particular, while the median still describes the typical case.

When mean and median are close, either is a fair summary. When the mean is much higher than the median the data is skewed to the right; a mean far below the median points to a left skew. Both numbers are available together in the mean, median and mode calculator, and the mean calculator covers the average on its own.

Useful properties and everyday uses

  • It is robust: replacing the largest value with one ten times bigger leaves the median unchanged.
  • At least half of the values are at or below it, and at least half are at or above it.
  • It works for ordered categories such as survey ratings, where averaging would be questionable.
  • It minimises the total absolute distance to the data, whereas the mean minimises the squared distance.

Typical uses include median household income, median home price, median response time (the p50 value in performance reports), median survival time in medical studies, and median exam score. If you need the most frequent value instead, try the mode calculator.

Common mistakes

  • Picking the middle entry of the list as typed instead of sorting it first.
  • Forgetting to average the middle pair when the count is even.
  • Counting positions from the wrong end, or off by one: with 9 values the median is the 5th, not the 4th.
  • Dropping repeated values. Duplicates count separately: 2, 2, 5, 9 has a median of (2 + 5) ÷ 2 = 3.5.

Frequently asked questions

How do you find the median of an even set of numbers?

Sort the numbers, take the two in the middle and average them. For 4, 6, 10 and 20 the middle pair is 6 and 10, so the median is 8.

Does the median have to be one of the numbers in the list?

Only when the count is odd. With an even count the median is the average of two values and may lie between them or equal a value that was not in the list.

Is the median affected by outliers?

Very little. Making the largest or smallest value more extreme does not change the order of the data, so the median stays put. This is the main reason to prefer it over the mean for skewed data.

What happens if I enter text or leave gaps?

Extra separators are ignored, but any other piece of text that is not a number is treated as zero and included in the count and the sorting. Remove it before calculating.

References

  1. NIST/SEMATECH e-Handbook of Statistical Methods, measures of location

Cite this calculator and page

If you use this page in your work, you can cite it as:

Reeliy Editorial Team. (2026). Median Calculator. Reeliy. https://reeliy.com/calculators/median-calculator“Median Calculator.” Reeliy, 2026, https://reeliy.com/calculators/median-calculator.