Mutation Score Calculator
Work out mutation score instantly with clear inputs, formula shown and shareable results.
About Mutation Score Calculator
Mutation testing injects small behavioural changes and checks whether the suite notices. The score is killed mutants over viable ones, excluding equivalent mutants that cannot change observable behaviour. The gap against line coverage is the interesting number: a large gap means tests execute the code without asserting on it, which is the failure mode line coverage cannot see.
Formula
Mutation score
viable = generated - equivalent; score = killed / viable; gap = line coverage - mutation score
Worked example
With the default values below, Mutation Score Calculator returns Mutation score of 70.27%. Change any input above and every figure here is recalculated in your browser.
Inputs used
- Mutants generatedminimum 1
- 2,400
- Mutants killed by testsminimum 0
- 1,560
- Equivalent or unviable mutantsminimum 0
- 180
- Line coverage for comparisonaccepts 0–100 %
- 85 %
Results
- Mutation score
- 70.27%
- Surviving mutants
- 660
- Viable mutants tested against
- 2,220
- Gap between line coverage and mutation score
- 14.73%
Step by step
- 1Values used
- 2Mutation score
- 3Mutation score= 70.27
- 4Surviving mutants= 660
- 5Viable mutants tested against= 2,220
- 6Gap between line coverage and mutation score= 14.73
Assumptions and limits
- The result is derived only from the 4 inputs listed above. Anything not among them is not part of the calculation.
- In particular, this calculator does not take inflation, tax, fees or charges or compounding frequency into account.
- Figures are rounded for display to 2 decimal places, so totals built from several rounded parts can differ slightly from the unrounded arithmetic.
How these calculators are built and tested is described on the Methodology page. If a figure looks wrong, please report it.
Frequently Asked Questions
Why is mutation testing so slow?
The suite must run once per mutant. Practical tools mitigate this with coverage-guided selection so only tests touching the mutated line are run.
What mutation score is good?
Above 70 percent on core business logic is strong. Applying it to the whole codebase is usually too slow, so scope it to the modules where correctness matters most.
Related Calculators
You might also need
- Apdex Score CalculatorAlso in DevOps, SRE & Performance
- DORA Metrics Score CalculatorAlso in DevOps, SRE & Performance
- Release Readiness Score CalculatorAlso in DevOps, SRE & Performance
- Artifact Retention CalculatorAlso in DevOps, SRE & Performance
- Automation ROI CalculatorAlso in DevOps, SRE & Performance
- Autoscaling Threshold CalculatorAlso in DevOps, SRE & Performance
