Statistical

MEDIAN Formula

MEDIAN returns the middle value in a set of numbers when sorted in order. Unlike AVERAGE, it is not skewed by extreme outliers, making it the go-to measure for things like household income, home prices, or response times where a few very large values would distort the mean.

Syntax

MEDIAN(value1, [value2, ...])
ParameterDescription
value1 Parameter of the MEDIAN function.
[value2 (Optional.) Parameter of the MEDIAN function.
...] Parameter of the MEDIAN function.
Try MEDIAN in Viztab — free, no signup

Examples

Median home price

Formula
=MEDIAN(C2:C150)
Returns the middle sale price from 149 home sales. If sorted, this is the 75th value — half the homes sold for more, half for less.

Median of specific values

Formula
=MEDIAN(12, 15, 100, 18, 14)
Returns 15. The sorted list is 12, 14, 15, 18, 100 — the middle value is 15. Note how the outlier (100) doesn't pull the result up like AVERAGE would.

Median response time

Formula
=MEDIAN(E2:E5000)
Returns the median server response time. Useful because a few slow requests (timeouts) won't inflate this metric the way an average would.

Common Errors

#NUM!

Returned when the range contains no numeric values. At least one number is required.

#VALUE!

Occurs if a non-numeric argument is supplied directly, such as =MEDIAN("abc").

Tips

Even number of values

When there is an even count of numbers, MEDIAN returns the average of the two middle values. For example, MEDIAN(1,3,5,7) returns 4.

Better than AVERAGE for skewed data

Use MEDIAN instead of AVERAGE when your data has extreme values. Salary data is a classic case — a few executives earning millions would inflate the average far above what most employees actually earn.

Combine with IF for filtered median

There is no built-in MEDIANIF, but you can use an array formula like =MEDIAN(IF(A2:A100="East",B2:B100)) to get the median for a specific group.

Try MEDIAN in Viztab

Import your data and use MEDIAN with 370+ other formulas. No signup required.

Open Viztab

Related Formulas