Root cause analysis

The 5 Whys,
worked end to end

Short answer

What is the 5 Whys method?

The 5 Whys is a root cause analysis technique that starts from one stated problem and asks "why" repeatedly — five times is the convention — until the chain reaches a cause the team can act on. Each answer has to be supported by evidence, not by the previous answer's wording. The method works on a single causal chain. It is a poor fit when several independent causes combine, and it stops being useful when a "why" is answered with a person's carelessness instead of a system condition.

The method

When it works, and when it does not

The 5 Whys works when one mechanism produced the incident and the record can support each step: a timeline, a change log, measurements. The discipline is in the evidence rule. Every answer has to point at something observed — a file size, a crash signature, a change timestamp — or the chain becomes five rounds of guessing with increasing confidence.

It fails in three recognizable ways. First, branching: real incidents often have several causes that had to coincide, and a single chain keeps whichever branch the room picked first. Second, drift: without evidence, each why slides toward the answer that sounds deepest. Third, the person stop: a chain that ends at "the engineer made an error" has stopped one why too early — the useful question is what condition made that error available and invisible. The worked example below keeps the main chain and then lists the contributing conditions separately, which is how the method survives contact with a real outage.

Worked example

The five whys on Cloudflare's November 18, 2025 outage

The problem. On November 18, 2025 at 11:20 UTC, Cloudflare's network began failing to deliver core traffic. Users saw Cloudflare error pages and HTTP 5xx volumes spiked — then fluctuated, recovering and failing again, a pattern the team first read as a hyper-scale DDoS attack. The full record is the casebook's Cloudflare outage case, drawn from Cloudflare's own postmortem. Every answer below is taken from that record; the evidence line under each answer says where.

  1. Why 1

    Why did the network return HTTP 5xx?

    The core proxy panicked. When the Bot Management module loaded its feature file, the FL2 Rust code called Result::unwrap() on the resulting error. The thread panicked, the proxy failed, and traffic that needed the bots module got HTTP 5xx.

    Case timeline, step 6: the crash mechanism identified in the proxy code.

  2. Why 2

    Why did the feature file make the module fail?

    The file had grown past the module's preallocated limit. A normal file holds about 60 features. This one held over 200 entries — beyond the hardcoded limit of 200 the module was built to accept.

    Case timeline, step 3: the file measured at over 200 entries against a normal ~60.

  3. Why 3

    Why did the feature file grow?

    The query that generates it returned duplicate rows. The generator read table metadata from system.columns, and the result now contained the same features twice — once from the default database and once from the underlying r0 database.

    Case timeline, step 4: the oversized file traced to the ClickHouse generator query.

  4. Why 4

    Why did the query start returning r0 rows that morning?

    A ClickHouse permissions change at 11:05 UTC made table access explicit. Before the change, the query only saw the default database. After it, the same query also returned r0 metadata. Symptoms began at 11:20 UTC, fifteen minutes later.

    Change record in the case evidence: the 11:05 UTC permissions change against the 11:20 UTC onset.

  5. Why 5

    Why was the query exposed to a permissions change at all?

    It was written without a database-name filter, so what it returned silently depended on implicit access semantics — on what the caller's permissions happened to make visible. The case names this as the latent assumption: when the semantics changed, the output changed with them, and nothing in the query announced it.

    Key turning point in the case record: "the metadata query never filtered on database name."

The root cause, in the case's own terms: the ClickHouse permissions change caused the unfiltered system.columns query to return duplicate metadata rows from both databases; the feature file more than doubled past the module's 200-feature limit; and the unhandled Result::unwrap() on that error panicked the core proxy, producing HTTP 5xx across the network.

What sits off the chain. Two contributing conditions made this outage global instead of local, and neither is on the five-whys path: the error handling panicked on a configuration-load path in the critical request pipeline, and the size limit was hardcoded with no graceful degradation. The case also records why the chain was hard to find in real time: the feature file regenerated every five minutes while the permissions change rolled out gradually, so good and bad files alternated across the network — the fluctuation that made an internal error look like an attack. A 5 Whys that stops at the root cause and skips this section will understate the fix list. The case's lessons start with fault isolation: a non-critical subsystem's failure must never be able to panic the critical path.

For the document this analysis lives in, see what an incident postmortem is. For more incidents organized by mechanism, see the root cause analysis examples.

Blank template

The 5 Whys template

Copy the block into the incident document. One row per why; the evidence column is not optional. If a row's evidence cell is empty, the chain is a draft, not a result.

Problem: [the observed failure, with start time and user-visible effect]

Why 1: Why did [problem] happen?
Answer: [...]
Evidence: [measurement, log line, change record]

Why 2: Why did [answer 1] happen?
Answer: [...]
Evidence: [...]

Why 3: Why did [answer 2] happen?
Answer: [...]
Evidence: [...]

Why 4: Why did [answer 3] happen?
Answer: [...]
Evidence: [...]

Why 5: Why did [answer 4] happen?
Answer: [...]
Evidence: [...]

Root cause: [the final answer, stated as a system condition]
Contributing conditions: [conditions off the chain that widened the impact]
What will change: [the change each cause points to, with an owner]
StepQuestionAnswerEvidence
ProblemState the failure, its start time, and who was affected.
Why 1–5Ask why of the previous answer. Stop at a system condition a change can fix.
Root causeThe last answer, restated on its own line.
Contributing conditionsAnything that widened the impact but is not on the chain.

Direct answers

Questions about the 5 Whys

What is the 5 Whys method?

The 5 Whys is a root cause analysis technique: state one problem, then ask why it happened, and why that happened, five times by convention. Each answer needs evidence. The chain ends at a system condition a team can change — not at a symptom, and not at a person's mistake.

What is an example of the 5 Whys?

Cloudflare's November 18, 2025 outage, worked above: the proxy panicked on an oversized Bot Management feature file; the file doubled because a metadata query returned duplicate rows; the query had no database filter; and a ClickHouse permissions change that morning exposed a second database to it.

How many whys should you ask?

Five is a convention, not a rule. Stop when the chain reaches a cause stated as a system condition that a named change can fix — a missing filter, an unhandled error, an absent limit check. If the third why already lands there, stop. If the fifth is still a symptom, keep going or switch methods.

When does the 5 Whys fail?

It fails when several independent causes combine, because one chain silently picks one branch. It fails when a why is answered from plausibility instead of evidence, and when the chain ends at a person's mistake. Cloudflare's outage also had contributing conditions off the chain — a panicking error path, a hardcoded limit.

What is the difference between the 5 Whys and root cause analysis?

Root cause analysis is the full reasoning from symptoms to mechanism, including the hypotheses that lost. The 5 Whys is one technique inside it: a disciplined way to walk a single chain. A postmortem usually needs more than the chain — the timeline, the evidence, the contributing conditions, and the changes that follow.

Is there a 5 Whys template?

Yes — the blank template is on this page: one row per why, a column for the evidence behind each answer, and separate lines for the root cause and the contributing conditions, so conditions off the chain cannot be quietly absorbed into it. Fill it from the record, not memory.