flameprof
cProfile flamegraph generator
What it is and what it does
Flameprof reads Python cProfile statistics and generates flamegraph visualizations to help you understand where your code spends time. It addresses a key limitation of cProfile's built-in reporting—which can be verbose and hard to parse—by rendering call stacks as compact, interactive flamegraphs. You profile your script normally using cProfile, then pipe the .prof file through flameprof to get an SVG you can open in a browser and explore by clicking.
The tool offers two output modes: native SVG with interactive features like tooltips showing cumulative and total timings and call counts, or a trace log format that feeds into the flamegraph.pl script. The native SVG mode includes visual cues like green bars to indicate where flameprof estimates timing ratios, and supports an inverted view to show total time across all calls. It's designed for developers, system administrators, and performance engineers who need to profile Python applications and visualize the results clearly.
Use it for:
- Profile a long-running Python service to identify bottlenecks and understand which functions consume the most CPU time.
- Generate an interactive SVG flamegraph from a cProfile dump to share with team members for performance review.
- Replace gprof2dot for Python profiling when you want cleaner, less noisy visualizations of call stacks.
- Export cProfile data as a trace log and process it with flamegraph.pl for further customization or analysis.
- Analyze batch job performance by profiling the script, generating a flamegraph, and drilling into specific call paths.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Converts Python cProfile statistics into interactive flamegraph visualizations, either as native SVG or as trace logs compatible with flamegraph.pl.
No. The package is abandoned (last commit 2023-03-23, latest release 2018-12-25) and likely has compatibility issues with modern Python versions. While it solves a real problem—making cProfile output readable—the lack of maintenance, combined with high install friction from a source tarball distribution, makes it a poor choice for new projects. Consider maintained alternatives for production profiling workflows.
Install
flameprof on PyPI
pip
pip install flameprofuv
uv add flameprofpoetry
poetry add flameprofInstalling flameprof
Before you install
High install friction: the package is archived (last commit 2023-03-23) and abandoned. No runtime dependencies, but the distribution itself is a source tarball, suggesting potential build or extraction steps. Not actively maintained.
License in practice
MIT license is permissive and poses no restrictions on use, modification, or distribution in commercial or private projects.
Quickstart
pip install flameprof
python -m cProfile -o myscript.prof myscript.py
flameprof myscript.prof > output.svg
Requires a cProfile .prof file as input; the package itself is no longer maintained and may have compatibility issues with modern Python versions.
Verify before relying
- Whether the package works reliably with Python 3.10+ given its abandonment and last release in 2018.
- Whether the source tarball distribution requires compilation or has undocumented system dependencies.
- Compatibility with modern versions of flamegraph.pl when using --format=log output.
Package facts
| License | MIT (permissive) |
| Python support | not specified |
| Install friction | high — source build required |
| Runtime dependencies | none |
| Maintenance | abandoned — 2,789 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 621,844/month — #5,713 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: flameprof-0.4.tar.gz
Tags
More Scientific/Engineering packages
NumPy provides an N-dimensional array object…
permissive · top 100 on PyPI
pandaspandas provides fast, flexible data structures…
permissive · top 100 on PyPI
scipyscipy provides numerical algorithms for…
permissive · top 100 on PyPI
scikit-learnscikit-learn provides a comprehensive Python…
permissive · top 1,000 on PyPI
dilldill extends Python's pickle module to…
permissive · top 1,000 on PyPI
multiprocessMultiprocess is an enhanced fork of Python's…
permissive · top 1,000 on PyPI
gprof2dotConverts profiler output from many sources…
copyleft · top 5,000 on PyPI
pytest-profilingPytest plugin that profiles test execution…
permissive · top 5,000 on PyPI
pyprof2calltreeConverts Python cProfile profiling data into…
permissive · top 15,000 on PyPI
djdt-flamegraphIntegrates flame graph visualization into…
permissive · top 15,000 on PyPI
tunatuna visualizes Python performance profiles in…
copyleft · top 15,000 on PyPI
django-cprofile-middlewareMiddleware that profiles Django view execution…
permissive · top 15,000 on PyPI
viztracerVizTracer traces Python code execution and…
permissive · top 5,000 on PyPI
py-spypy-spy is a sampling profiler that attaches to…
permissive · top 1,000 on PyPI
snakevizSnakeViz is a web-based viewer for Python…
permissive · top 5,000 on PyPI
line-profilerline_profiler measures execution time on a…
permissive · top 5,000 on PyPI