Skip to the content
Know your tech before you buy it. Makers: get listed from $49/mo

mutmut

mutmut.readthedocs.io

  • Free plan
  • Windows
  • macOS
  • Linux
  • Self-hosted

What mutmut is

mutmut is an open-source mutation testing system for Python. It makes changes to code, called mutants, to help developers see whether their tests detect those changes. Its listed mutation operators increment integer literals by 1, change < to <=, and swap break and continue. The tool works with pytest and remembers completed work so runs can continue incrementally. It selects tests to execute for each mutant and offers an interactive terminal interface for browsing results. Users can write a mutant to disk from that interface or use the mutmut apply command, then add tests and rerun individual mutants. Configured coverage.py integration can limit mutations to covered lines. The documentation supports filtering mutants with mypy or pyrefly, but not pyright or ty. mutmut can export CI/CD statistics and generate mutation score badge JSON for a Shields endpoint. It requires Python 3.10 or later and a system with fork support, so Windows users need WSL. Version 3 and later mutate code inside functions; version 2 uses a different model for code outside functions. The package is licensed under BSD-3-Clause.

Who it suits

mutmut suits Python developers using pytest who want to check whether tests catch small code changes. It also fits teams using incremental mutation runs or CI/CD statistics.

Good to know, and what to watch

  • Continues mutation testing incrementally
  • Selects tests for each mutant
  • Interactive terminal interface for browsing mutants
  • Optional coverage.py, mypy, and pyrefly filtering
  • Exports CI/CD statistics and badge JSON
  • Requires Python 3.10 or later
  • Windows users must run it inside WSL
  • Requires a system with fork support
  • pyright and ty filtering are unsupported

The verdict

mutmut provides a focused workflow for finding gaps in Python tests, with incremental runs and optional filtering. Check the fork-support requirement and supported type-checker filters before adopting it, especially on Windows.

What the maker publishes

Applying mutants
Users can write a mutant to disk from the browse interface or with the mutmut apply command. source
CI output
mutmut can export CI/CD statistics and generate mutation score badge JSON for a Shields endpoint. source
CI output
It can export CI statistics and create mutation score badge data for a Shields endpoint. source
Configuration
Configuration is supported in setup.cfg or pyproject.toml, including source paths and pytest test selection arguments. source
Coverage and type checking
Optional filters can use coverage.py to select covered lines and mypy or pyrefly to filter invalid mutants. source
Coverage integration
mutmut can use coverage.py to filter mutations to covered lines when configured. source
Distribution
The PyPI listing shows mutmut version 3.8.0, released September 12, 2026. source
Incremental runs
It remembers completed work so mutation testing can continue incrementally. source
Incremental runs
It remembers completed work so mutation testing can continue incrementally. source
Interface
It provides an interactive terminal-based UI for browsing mutants. source
Interface
It provides an interactive terminal based interface for browsing mutants. source
License
The package is distributed under the BSD-3-Clause license. source
Mutation scope
The documentation says mutmut 3 and later mutate code inside functions, while mutmut 2 has a different execution model for code outside functions. source
Operating system requirement
mutmut requires a system with fork support; Windows users must run it inside WSL. source
Parallel execution
The project describes execution as parallel and fast. source
Parallel execution
The project lists parallel and fast execution as features. source
Purpose
mutmut is a mutation testing system for Python focused on ease of use. source
Purpose
mutmut is a mutation testing system for Python focused on ease of use. source
Pytest
A basic run invokes pytest on tests in a tests or test folder. source
Python requirement
The package requires Python 3.10 or later. source
Security and compliance
The project repository identifies its license as BSD-3-Clause. source
Test selection
It identifies which tests to execute for mutants to speed up mutation testing. source
Test selection
It determines which tests to execute for a mutant to speed up mutation testing. source
Type checker integration
The documentation supports filtering mutants with mypy or pyrefly and says pyright and ty are not currently supported for this purpose. source

Checked against the maker's pages on 8 Oct 2026.