pytest-benchmark
Pytest fixture for benchmarking code with statistical analysis, comparing runs across commits and generating rich performance reports.
Our Verdict
The go-to Python microbenchmarking tool for catching performance regressions inside your test suite.
Pros
- Statistical analysis of test runs built-in
- Compares benchmarks across git commits
- Rich HTML and JSON report output
- Low friction, just add a fixture
Cons
- Microbenchmarks, not load testing
- Python-only, no cross-language comparison
- CI noise can skew results without pinning
Best for: Python libraries guarding hot paths against per-commit performance regressions
Not for: Whole-system load testing where Locust or k6 are proper fits
When to Use pytest-benchmark
Good fit if you need
- Statistical performance benchmarking in pytest suites
- Compare benchmark results across git commits in CI
- Track performance regressions in algorithmic code
- Rich histogram and timing reports for optimization work
Lock-in Assessment
Low 5/5
Lock-in Score 5/5
Pricing
Price wrong?pytest-benchmark Pricing
- Pricing Model
- free
- Free Tier
- Yes
- Entry Price
- —
- Enterprise Available
- No
- Transparency Score
- —
Beta — estimates may differ from actual pricing
1,000
1001K10K100K1M
Estimated Monthly Cost
$25
Estimated Annual Cost
$300
Estimates are approximate and may not reflect current pricing. Always check the official pricing page.
Project Health
C
Health Score
1.4k 132
Bus Factor
3
Last Commit
26 days
Release Freq
N/A
Open Issues
119
Issue Response
N/A
License
BSD-2-Clause
Last checked: 2026-04-21
Community Discussion
Comments powered by Giscus (GitHub Discussions). You need a GitHub account to comment.