# Quartile and IQR Calculator

URL: https://speedycalculator.com/calculators/statistics/quartile/
Last updated: 2026-10-25

> The quartile calculator finds the first quartile (Q1), median (Q2), third quartile (Q3), interquartile range and the outlier fences used in box plots.

## Inputs

- Data

## Results

- Q1 (25th percentile)
- Median (Q2)
- Q3 (75th percentile)
- Interquartile range
- Lower fence
- Upper fence

## Formula

```
IQR = Q3 − Q1
Lower fence = Q1 − 1.5 × IQR,  Upper fence = Q3 + 1.5 × IQR
```

## Explanation

Quartiles split sorted data into four equal parts. Values beyond the fences are often flagged as outliers.

### How to use the Quartile and IQR Calculator

- **Data**

Results update as you type, and every field accepts the units shown in its menu.

### How it works

Quartiles are computed by linear interpolation between ranked values (the same method as Excel’s QUARTILE.INC).

### What each result means

- **Q1 (25th percentile)** = [Q1 (25th percentile)]([Data])
- **Median (Q2)** = median([Data])
- **Q3 (75th percentile)** = [Q3 (75th percentile)]([Data])
- **Interquartile range** = [Q3 (75th percentile)] - [Q1 (25th percentile)]
- **Lower fence** = [Q1 (25th percentile)] - 1.5×[Interquartile range]
- **Upper fence** = [Q3 (75th percentile)] + 1.5×[Interquartile range]

## Worked example

Inputs — Data: 6, 7, 15, 36, 39, 40, 41, 42, 43, 47, 49.

Results — Q1 (25th percentile) = 25.5; Median (Q2) = 40; Q3 (75th percentile) = 42.5; **Interquartile range = 17**; Lower fence = 0; Upper fence = 68.

## FAQ

**Why do other tools give slightly different quartiles?**
There are several quartile methods; this uses linear interpolation (type 7).

**What is a five-number summary?**
Minimum, Q1, median, Q3 and maximum.

**What formula does the Quartile and IQR Calculator use?**
IQR = Q3 − Q1.


## Sources

- [NIST/SEMATECH e-Handbook of Statistical Methods](https://www.itl.nist.gov/div898/handbook/)
