Skip to content

SLOs and error budgets: how to agree with the business what "fast" means

B2Bnetwork team · · 6 min

System performance

In brief

An SLO (service level objective) is an agreed target for a measurable characteristic of a service, e.g. "99% of logins complete in under 1 s over a 30-day window". The error budget is the allowed remainder: with a 99.9% target, that is 0.1% of requests, or about 43 minutes in 30 days. This turns "fast" and "reliable" into numbers that the business and the IT team approve together, and the budget tells you when you can ship new features and when you need to focus on reliability.

SLI, SLO, and SLA: three different things

The Google SRE book separates three concepts that often get mixed up in conversations with the business:

ConceptWhat it isExample
SLI (service level indicator)a measure: the ratio of good events to all eventsthe percentage of logins completed successfully in under 1 s
SLO (service level objective)an internal target for that measure over a time window99% in every rolling 30-day window
SLA (service level agreement)a contract with the customer with consequences for missing it99.5% availability per month, below that a discount on the fee

You set the SLO stricter than the SLA, so that the team has time to react before the company pays a contractual penalty. An SLO without an SLA also makes sense: in an internal system, or in a service that other teams depend on, the SLO is what tells you what to expect.

How to turn "fast" into a number

You turn "fast" into a number in four steps, ideally in one meeting with the product owner and the technical team.

  1. Choose the customer journeys that count. In online banking: login, balance view, and transfer; in an e-recruitment system: submitting an application in the last hours before the deadline; at an operator: service activation. Three to five journeys are enough to start.
  2. Define what a good event is. For example: a transfer completed successfully and confirmed in under 1.5 s, measured at the entry to the system. Time is recorded as a threshold for a given percentage of requests, not as an average; why is explained in the article Percentiles instead of averages.
  3. Measure the current state. Data from the last few weeks of production shows what percentage of events meets the condition. You set the target at a level that users consider sufficient and that the system actually achieves, not at the level of a wish.
  4. Choose a time window. Usually a rolling window of 28 or 30 days. A shorter window reacts faster but fluctuates more.

The Google SRE book points out that 100% is a bad target: users cannot tell a very highly reliable service from the reliability of their own phone and network anyway, and every additional nine costs noticeably more and slows down change.

The error budget: how much you are allowed to get wrong

The error budget is one minus the SLO. With a 99.9% target the budget is 0.1%, which can be converted into events or into time:

SLOBudgetIn 30 days (43,200 minutes)At 10 million requests in the window
99%1%432 minutes, approx. 7.2 h100,000 failed
99.5%0.5%216 minutes, approx. 3.6 h50,000 failed
99.9%0.1%43.2 minutes10,000 failed
99.95%0.05%21.6 minutes5,000 failed

Converting to minutes is a simplification that helps in a conversation with the business. In practice the budget is counted in events: with a request-based SLO, an outage at night, when traffic is low, uses less budget than the same outage at the peak.

The error budget changes the conversation about risk. As long as there is budget, the team can ship changes, experiment, and do work that carries risk. When the budget runs out, reliability becomes the priority.

Budget policy: what we do when it runs out

A budget makes sense only if it was agreed in advance what happens once it is exhausted. Such a document is an error budget policy, signed by the product owner and the technical lead. The Google SRE workbook (The Site Reliability Workbook) contains an example. Typical arrangements:

  • once the budget in the window is exhausted, deployments of new features are paused, except for security and reliability fixes,
  • the team analyzes the incidents that consumed the most budget and plans fixes,
  • deployments resume when the SLO in the rolling window is met again,
  • disputes are settled by a person named in advance, not by a discussion at every incident.

For alerting you use the rate at which the budget is consumed (burn rate) instead of a simple threshold. An alert fires when the budget disappears fast enough that at this rate it would run out long before the end of the window. A short spike in errors that uses a small part of the budget does not wake the on-call engineer at night.

SLOs, performance tests, and reviewing targets

The SLO links production with performance testing. The same threshold that defines a good event in production becomes the pass criterion of a load test before release and an absolute threshold in the CI/CD pipeline; this is described in the article Performance tests in CI/CD without false alarms. Before a core system migration or a sales peak, the test shows whether the new version will fit within the SLO at forecast traffic.

Measuring an SLI requires data from the system: response time metrics as histograms and counters of successful and failed requests, described in the article Observability: logs, metrics, and traces.

You review targets every quarter or after a major change. If the SLO is consistently met with a large margin and users report problems, you are measuring the wrong thing. If the SLO is consistently missed and nobody complains, the target is probably too strict. It is good to compare performance test results before every SLO change with production data; an example of such tests is the case study Performance testing of an e-recruitment system.

Questions and answers

How does an SLO differ from an SLA?

An SLO is the team's internal target for a measurable characteristic of a service, e.g. the percentage of fast and successful logins. An SLA is a contract with the customer that provides for consequences, e.g. a discount, when the service does not keep its promise. You set the SLO stricter than the SLA, so that the team has time to react before missing the contract starts costing the company money.

How many SLOs should a single service have?

Few, usually one to three: availability, meaning the percentage of successful requests, response time for key operations, and sometimes data freshness or processing correctness. Every additional SLO has to be measured, reviewed, and defended in conversation with the business, and too many targets dilute the team's attention.

How do I convince the business that 100% is a bad target?

Show the cost and benefit in numbers. A budget of 0.1% in 30 days is about 43 minutes; going down to 0.01% gives about 4 minutes and usually requires much greater spending, slower deployments, and additional infrastructure. It is also worth showing that the customer experiences interruptions anyway because of their own network and device.

What should we do when the error budget runs out mid-window?

Apply the policy agreed in advance: usually pause deployments of new features except for reliability and security fixes, analyze the incidents that consumed the budget, and plan fixes. When the SLO in the rolling window is met again, deployments resume. Without a policy agreed beforehand, the same decision turns into a dispute at every incident.

What it looks like in a project

Your system slows down under load? We'll find where it loses time.

Let's talk

Read more: System performance