Services

Our Work

Company

Explore

Explore

/

Percentile latency

Percentile latency (p95 and p99)

Percentile latency is the response time that a given share of requests stay under. p50 is the median, p95 is the time 95% of requests beat, and p99 is the time 99% beat. Percentiles show the slow tail of requests that an average hides, which is often where users notice a problem first.

How to calculate it

Sort request durations from fastest to slowest and read the value at the chosen rank. With 1,000 requests, p99 is roughly the 990th value. Suppose 980 requests take 100 ms and 20 take 5 seconds. The average is about 198 ms and looks healthy, but p99 is 5 seconds. In production, tools estimate percentiles from histograms, so bucket boundaries affect accuracy. Percentiles from different servers cannot be averaged together; merge the histograms instead.

Why it matters in production

A page that makes 20 backend calls has about an 18% chance (1 minus 0.99 to the power 20) that at least one call is slower than p99. Tail latency becomes the experience of many users. Setting latency SLOs and alerts on p95 or p99 catches degradation that an average would miss.

See also

On the One2N blog

References

  1. Origin of the term

  2. Histograms and summaries (Prometheus documentation)

  3. Service level objectives (Google SRE book)

Bar chart of 1,000 request times sorted fastest to slowest. 980 requests take 100 ms and form a low green strip, so p50 is 100 ms. A dashed average line sits just above it at 198 ms and looks healthy. At the far right, a thin red bar shows the slowest 20 requests at 5 s, and an arrow marks p99 = 5 s, the tail the average hides.

Putting this into practice?

Talk to One2N about our SRE consulting

Talk to One2N about our SRE consulting