Skip to main content

formula

Median Formula Explained

Complete Median formula reference with variables, units, and examples.

Middle value of sorted data (average of two middle values if n is even)

This reference explains the Median formula used by our free Median Calculator. Use it to understand variables, units, and common mistakes before you calculate.

The formula

Middle value of sorted data (average of two middle values if n is even)

Variables and units

  • median — Middle value when data is sorted (same as data)
  • n — Number of observations (count)

Worked example

Inputs: Data: 3, 1, 4, 1, 5, 9, 2, 6

  1. Sort: 1, 1, 2, 3, 4, 5, 6, 9
  2. n = 8 (even), median = average of 4th and 5th values
  3. Median = (3 + 4) / 2 = 3.5

Result: Median = 3.5

When to use this formula

Use this formula when you need a quick median estimate with values you already know. Our Median Calculator applies the same relationship automatically so you can verify handwritten work.

Common mistakes

  • Not sorting data before finding median
  • Using mean formula for median
  • Forgetting to average two middle values when n is even

Frequently asked questions

What formula does the Median Calculator use?

It uses: Middle value of sorted data (average of two middle values if n is even). Enter your values and the calculator returns the result with the same relationship.

Can I use different units?

Check the calculator field labels for expected units. Convert inputs before calculating if your data uses different units.

Is the Median Calculator free?

Yes. It runs entirely in your browser with no account required.

Try the calculator

Median Calculator