Understand
Counterfactual Explanation
What would have changed the outcome?
Shows the smallest realistic change that would have produced a different result, making the decision boundary visible.
- Evidence: research-based (Wachter et al. 2017, Karimi et al. 2021)
- Tested: concept only, mock data
Overview
Why it matters
The question after “why” is always “what if”.
Attribution shows what mattered. A counterfactual shows what would have changed the outcome: “With €500 more income per month, this application would have been approved.” It answers the question people ask right after an adverse decision.
It’s not the same as Actionable Recourse. A counterfactual describes the decision boundary. Recourse filters it down to what this person can realistically do.
What does it look like?
Understanding a borderline decline
Understanding a borderline decline
- Applicant sees their declined decision.
- Below the attribution: “What would have changed this?” section.
- System shows: “If your monthly debt payments had been €150 lower, the application would have been approved.”
- Applicant clicks through to: “How can I improve this?”: recourse section explains debt reduction options and reapplication timeline.
Caseworker assessing an edge case
Caseworker assessing an edge case
- Caseworker reviews a case at the exact threshold: score 48, referral threshold 50.
- Counterfactual panel shows: “This case is 2 points below the approval threshold. The closest factor to the boundary is employment verification: if confirmed by a third-party source, the score would reach 52.”
- Caseworker requests employment verification before making the override decision.
Multi-factor case
Multi-factor case
- Applicant with several borderline factors asks what would change the result.
- System shows: “No single factor change would change the outcome. However, if both of these changes were in place: [income ratio below 38%] AND [employment gap under 6 months], the application would be approved.”
- Applicant understands the full picture and assesses whether both changes are achievable.
When does it fit?
Use it when
- The decision was adverse and people want to know what would have changed it
- Some of the factors are within the person’s control
- Professionals need to see where the decision boundary lies
Skip it when
- Showing the boundary would invite gaming
- Nothing that would change it is within the person’s control
- The model is too unstable for the answer to hold
Design
How do I apply it?
-
Lead with the most plausible change.
The mathematically smallest change can be practically impossible. Prefer what people can act on.
-
Use everyday terms.
“€200 less in monthly debt” beats “a ratio of 0.43 instead of 0.51”.
-
Be honest about combinations.
If two or three things would have to change together, say so.
-
Don’t promise outcomes.
It describes this decision, not a guarantee for the next one.
-
Connect it to recourse.
The next question is “so what can I do?” Don’t make it a dead end.
For your technical team
Counterfactual generators often return the minimal-distance change in feature space, which can be implausible or involve immutable features. Constrain the search to actionable features and plausible values, and check that the counterfactual is stable for nearby inputs before showing it.
How can I show it?
Minimum change statement
One sentence on the smallest change that would have mattered.
A plain-language sentence describing the smallest change that would have altered the outcome: “If your debt ratio had been below 35%, this application would have been approved.” Simple, direct, and actionable.
Near miss highlight
How close it was, and what was missing.
A specific version of the counterfactual for borderline cases: “This application came close: 3 of 5 key criteria were met. The two factors that were not met are: [X] and [Y].” Particularly useful for motivating reapplication.
Controllable vs. fixed factors
What the person can change, and what is fixed.
A visual distinction within the counterfactual between factors the user can actually change and factors that are fixed (age, historical records). This is the bridge between counterfactual and recourse.
Threshold visualization
Where the score sits relative to the decision line.
A simple visual showing where the current score sits relative to a decision boundary, and how far it is from a different outcome. A number line, progress bar, or gauge can make the proximity to the threshold visible without revealing the exact threshold number.
Counterfactual comparison card
Current profile and changed profile, side by side.
A side-by-side card showing the current profile vs. the counterfactual profile: with the changed factors highlighted. Users can immediately see what’s different.
Multi-factor counterfactual
When several factors would need to change together.
Some decisions require changes to multiple factors simultaneously. A counterfactual explanation that shows “changing factor A and factor B together would change the outcome” is more honest than implying a single-factor change is sufficient.
Further left for a quick answer, further right for complex, multi-factor decisions.
What does it cost?
Transparency vs. gaming
Counterfactuals reveal thresholds. Where gaming is a risk, show direction rather than exact values.
Helpfulness vs. false promise
Models and policies change. Qualify the statement.
Simplicity vs. completeness
A single-factor answer is easy, but misleading when several things must change.
Connections
Which patterns work with it?
Attribution
Why did the system make this decision?
Attribution and counterfactual explanation are complementary. Attribution answers “what mattered.” Counterfactuals answer “what would have changed it.” Together they form a complete explanation.
Actionable Recourse
What can I do to change this outcome?
Counterfactuals describe the decision boundary. Recourse translates that boundary into practical steps. Use counterfactual as the explanation, recourse as the action plan.
Inspection Dialogue
Can I ask the system follow-up questions?
“What if I had X instead of Y?” is a counterfactual question phrased as an inspection dialogue query. The two patterns overlap and can be combined.
Example-Based Explanation
What similar cases influenced this result?
The “near miss” counterfactual case is also a form of example: a real or illustrative case that was similar but different in outcome. The patterns reinforce each other.
Sources (3)
Sources (3)
Wachter et al. (2017) — Counterfactual Explanations without Opening the Black Box
introduces counterfactual explanations as a legally grounded approach to explaining algorithmic decisions. The paper directly motivates the GDPR-aligned use of counterfactuals for adverse decisions
Karimi et al. (2021) — Algorithmic Recourse: from Counterfactual Explanations to Interventions
makes the critical distinction between counterfactuals (what would change the outcome) and recourse (what the person can actually do). Essential for designing honest counterfactual interfaces
Ustun et al. (2019) — Actionable Recourse in Linear Classification
proposes recourse as a measurable property of classification systems and develops methods for identifying actionable changes. Provides the technical basis for distinguishing controllable from non-controllable factors in the counterfactual display
You tell people why they were declined, not what would have made the difference.
Common in financial services, benefits and hiring. That’s where this pattern starts. Let’s look at your interface together.
Work with me