# Python 3.15 sampling profiler

6 Hacker News commenters recommended Python 3.15 sampling profiler and 1 criticized it, November 2025 to November 2026. It was recommended in 3 of 13 months.

**Verdict:** Built into Python 3.15, it gives sampling profiling with strong reporting and a live mode. Critics note it cannot be switched on and off from code.

## Why people recommend it

- Excellent sampling profiler with reporting (2 comments): "features a very good sampling profiler with excellent reporting" ([source](https://news.ycombinator.com/item?id=46636537)) "the profiling looked very nice" ([source](https://news.ycombinator.com/item?id=48995375))

## What people warn about

- Cannot enable or disable from code (1 comments): "I don't see any way to enable/disable the profiler from code" ([source](https://news.ycombinator.com/item?id=46344582))

## Alternatives hackers recommend

- [perf](https://hackerapproved.com/p/perf.md): 13 recommend
- [Java Flight Recorder](https://hackerapproved.com/p/java-flight-recorder.md): 10 recommend
- [Instruments](https://hackerapproved.com/p/instruments.md): 9 recommend
- [Perfetto](https://hackerapproved.com/p/perfetto.md): 8 recommend
- [Heaptrack](https://hackerapproved.com/p/heaptrack.md): 5 recommend

## Cite as

Hacker Approved, "Python 3.15 sampling profiler", https://hackerapproved.com/p/python-3-15-sampling-profiler/ (counts from 1,795,640 Hacker News comments, November 2025 to November 2026).
