Sub topic 2
Reading the nines
This chapter assumes you know what availability means (the fraction of time or requests for which a service works correctly) and can read short Python snippets. It covers how to read the "nines" shorthand, convert it to downtime, and spot the common ways it misleads.
What the nines are
The nines notation counts the leading nines in an availability percentage:
- 99% is "two nines".
- 99.9% is "three nines".
- 99.99% is "four nines".
- 99.999% is "five nines".
The notation is popular because the interesting part of a high availability number is its unavailability. The difference between 99.9% and 99.99% looks like 0.09 percentage points. In practice it is a tenfold difference in how much downtime you may have.
Each added nine divides the unavailable fraction by 10:
| Availability | Unavailable fraction |
|---|---|
| 99% | 1 in 100 (0.01) |
| 99.9% | 1 in 1,000 (0.001) |
| 99.99% | 1 in 10,000 (0.0001) |
| 99.999% | 1 in 100,000 (0.00001) |
Converting nines to downtime
The conversion is one multiplication:
allowed downtime = (1 − availability) × length of the window
The window matters, so always state it. The same target gives different numbers per day, per 30-day month, and per year. The table uses a 365-day year (525,600 minutes) and a 30-day month (43,200 minutes).
| Availability | Per day | Per 30-day month | Per year |
|---|---|---|---|
| 99% | 14.4 min | 7.2 h | 87.6 h (3.65 days) |
| 99.9% | 1.44 min (86.4 s) | 43.2 min | 8.76 h |
| 99.95% | 43.2 s | 21.6 min | 4.38 h |
| 99.99% | 8.64 s | 4.32 min | 52.56 min |
| 99.999% | 0.86 s | 25.9 s | 5.26 min |
| 99.9999% | 0.086 s | 2.59 s | 31.5 s |
You can memorize a few anchors and scale from them:
- Three nines is about 9 hours per year.
- Four nines is about 1 hour per year.
- Five nines is about 5 minutes per year.
Each step down is a division by ten.
The first worked-out function below computes the table for any target and picks a readable unit.
def format_duration(seconds):
if seconds >= 3600:
return f"{seconds / 3600:.2f} h"
if seconds >= 60:
return f"{seconds / 60:.2f} min"
return f"{seconds:.2f} s"
def downtime_seconds(availability, window_days):
return (1 - availability) * window_days * 24 * 3600
for target in (0.999, 0.9999, 0.99999):
day = format_duration(downtime_seconds(target, 1))
month = format_duration(downtime_seconds(target, 30))
year = format_duration(downtime_seconds(target, 365))
print(f"{target:.3%} day={day} month={month} year={year}")
# 99.900% day=1.44 min month=43.20 min year=8.76 h
# 99.990% day=8.64 s month=4.32 min year=52.56 min
# 99.999% day=0.86 s month=25.92 s year=5.26 minReading it in reverse
Going from a percentage back to a number of nines uses a base-10 logarithm:
nines = −log10(1 − availability)
import math
def nines(availability):
return -math.log10(1 - availability)
for a in (0.99, 0.999, 0.9995, 0.9999, 0.99999):
print(f"{a:.3%} -> {nines(a):.2f} nines")
# 99.000% -> 2.00 nines
# 99.900% -> 3.00 nines
# 99.950% -> 3.30 nines
# 99.990% -> 4.00 nines
# 99.999% -> 5.00 ninesThe 99.95% line shows that "nines" does not have to be a whole number. A service at 99.95% sits about 0.3 nines above three nines, and its budget is half that of 99.9%.
Fractional nines and nonstandard targets
Real targets are often not clean powers of ten. Common ones include 99.5%, 99.95%, and 99.98%. The same formula applies. Two habits help:
- Compare targets by their unavailable fraction. 99.95% allows 0.05% of failure, which is half of 99.9%'s 0.1%.
- Say "three and a half nines" only informally. In a contract or an SLO, write the exact percentage and the window.
Some sources describe 99.95% as "three and a half nines" and others as "three nines five". Neither is a standard. The log formula gives 3.30 for it, so the "half" is only a rough label.
Why the window changes what the number means
A target is meaningless without its measurement window. Consider 99.9% over a month, which allows 43.2 minutes of downtime. Several policies are all compatible with that number:
- One 43-minute outage in the month.
- Forty-three one-minute outages.
- Thousands of short blips that add up to 43 minutes.
These feel very different to users, but the percentage cannot tell them apart. If you want to rule out a long single outage, add a separate limit, such as a maximum duration for any single incident.
A longer window is more forgiving. A bad hour that wrecks a 30-day window may be a small share of a rolling 365-day window. A short window of a day or a week catches problems sooner but leaves little room for a single incident. At 99.99%, a single 10-minute incident already exceeds the 4.32 minutes allowed in a 30-day month, and it still fits in a year's 52.56 minutes.
Conventions for the window also differ:
- A 30-day month is simple and gives round numbers. Calendar months run 28 to 31 days, so the budget changes slightly month to month.
- A 365-day year ignores leap years. Using 365.25 days gives 0.07% more time, which is rarely worth the confusion.
- A rolling window (the last 28 or 30 days, recomputed continuously) avoids the cliff at the start of each calendar period, when the budget resets.
Pick one convention and write it down. Two teams that disagree on the window will report different numbers for the same incident history.
Common errors when reading nines
- Treating the gap between nines as small. The step from 99% to 99.9% looks like less than one percentage point. It reduces the allowed downtime from 7.2 hours to 43.2 minutes per month.
- Forgetting the window. "We need 99.99%" is incomplete. Per month, per quarter, and per year each give a different downtime allowance.
- Rounding in the wrong direction. A measured 99.89% is not "three nines". It is below 99.9% and misses a 99.9% target. Truncate, never round up, when comparing against a target.
- Assuming time-based and request-based numbers match. A service that is fully down for 10 minutes at 3 a.m. loses far fewer requests than one that is down for 10 minutes at peak. The next chapter on measurement covers this difference.
- Reading marketing numbers as guarantees. A provider's "five nines" may describe a component under ideal conditions, exclude maintenance windows, or exclude regional failures. Check what counts as down before relying on it.
- Stacking nines on nines. If your service depends on three components, each at 99.9%, your service cannot exceed 99.7%. The chapter on dependencies in series covers that calculation.
Practical limits of high nines
Higher nines have a floor set by what you can detect and measure:
- A budget of 0.86 seconds per day (five nines) is shorter than most health-check intervals. A probe that runs every 10 seconds cannot measure it directly.
- A monitor that is itself 99.9% available cannot reliably verify a 99.999% claim.
- Clock skew, retries, and client-side caching blur the edges of short outages.
At those levels, the number is mostly a design goal. Measurement is usually done from request counts, not from a stopwatch on outages.
A quick method for reading any target
- Write the target as a percentage with its window, for example 99.95% per 30 days.
- Subtract it from 100% to get the unavailable fraction: 0.05%.
- Multiply by the window length in minutes: 0.0005 × 43,200 = 21.6 minutes.
- Compare that figure with how long your typical incident lasts, including detection and recovery.
If one typical incident uses up the whole budget, the target either needs a faster response or a lower number.
Exercise
A service has a 99.95% availability target measured over a 30-day month. How many minutes of downtime does it allow, and how many nines is that approximately?
Show answer
The unavailable fraction is 1 − 0.9995 = 0.0005. Multiplying by 43,200 minutes gives 21.6 minutes per 30-day month. The nines value is −log10(0.0005), which is about 3.30, so roughly three and a third nines. It is exactly half the downtime that 99.9% allows (43.2 minutes).
Exercise
Your monitoring reports 99.89% availability for the last 30 days. The SLO is 99.9%. Does the service meet it, and by how many minutes does it miss or beat the budget?
Show answer
No. The budget at 99.9% is 43.2 minutes. At 99.89% the unavailable fraction is 0.0011, so downtime was 0.0011 × 43,200 = 47.52 minutes. The service exceeded its budget by 4.32 minutes. Rounding 99.89% to "99.9%" would hide the miss.
Exercise
A team says it will deliver 99.999% availability, and its health check probes the service once every 30 seconds. Why is that probe too coarse to verify the claim, and what would you use instead?
Show answer
Five nines allows about 0.86 seconds of downtime per day, or 25.9 seconds per 30-day month. A single failed 30-second probe interval already represents more downtime than the whole monthly budget, and outages shorter than 30 seconds can fall between probes. Measure from request outcomes instead, for example the fraction of real requests that succeeded, which captures short failures and weights them by traffic.