# The Excel MEDIAN Function

## Function Description

The Excel MEDIAN function returns the statistical median (the middle value) of a list of supplied numbers.

The syntax of the function is:

MEDIAN( number1, [number2], ... )

where the number arguments are a set of one or more numeric values (or arrays of numeric values), for which you want to calculate the median

Note that:

• If there is an even number of values in the supplied data set, the average of the two middle values is returned;
• If a supplied array contains empty cells, text, or logical values, these values are ignored when calculating the median.
• In current versions of Excel (Excel 2007 & later), you can provide up to 255 number arguments to the Median function, but in Excel 2003, the function can only accept up to 30 number arguments. However, each of the number arguments can be an array of many values.

## Excel Median Function Examples

The following spreadsheet shows three examples of the Median function:

Formulas:
AB
11=MEDIAN( A1:A7 )
24.5=MEDIAN( A1:A7, 12 )
37=MEDIAN( A1:A8 )
48
59
613
714
8
Results:
AB
118
24.58.5
378
48
59
613
714
8

Note that, in the above examples:

• The example in cell B2 receives an even number of values and so the median is calculated to be the average of the two middle values, 8 and 9;
• The example in cell B3 includes the blank cell, A8. This cell is ignored in the median calculation.

For further details of the Excel Median function, see the Microsoft Office website.