bakame/stackwatch

A minimalist, embeddable, multi-metric, and framework-agnostic profiler for PHP

Maintainers

πŸ‘ nyamsprod

Package info

github.com/bakame-php/stackwatch

Documentation

pkg:composer/bakame/stackwatch

Fund package maintenance!

nyamsprod

Statistics

Installs: 65

Dependents: 1

Suggesters: 0

Stars: 9

Open Issues: 1

0.16.1 2026-02-07 11:18 UTC

Requires

Requires (Dev)

Suggests

Provides

None

Conflicts

None

Replaces

None

MIT 6ef71079c30e36c06105fda6d7c0003e2f3174af

profilerCPUstopwatchmicrotimeembeddablehrtimememory_usagemulti-metric

This package is auto-updated.

Last update: 2026-06-08 21:23:58 UTC


README

πŸ‘ Stackwatch

Stackwatch

πŸ‘ Author
πŸ‘ Software License
πŸ‘ Build
πŸ‘ Latest Version
πŸ‘ Total Downloads
πŸ‘ Sponsor development of this project

Stackwatch is a lightweight profiler for PHP 8.1+. It helps you measure performance with precisionβ€”without unnecessary complexity.

Stackwatch bridges the gap between basic timers and heavy profiling tools like PHPBench, Xdebug or Blackfire. It is perfect for:

  • Isolated performance testing
  • Annotated profiling of large codebases
  • Lightweight integration into dev workflows

Zero-dependency core. Optional CLI with familiar Symfony Console integration.

Installation

composer require bakame/stackwatch

You need:

  • PHP >= 8.1 but the latest stable version of PHP is recommended
  • the psr/log package or any package implementing the PHP-FIG log contract

To use the CLI command you will also need:

  • symfony/console and symfony/process

Documentation

Full documentation can be found at https://bakame-php.github.io/stackwatch/

Testing

The library has:

  • a PHPUnit test suite.
  • a coding style compliance test suite using PHP CS Fixer.
  • a code analysis compliance test suite using PHPStan.

To run the tests, run the following command from the project folder.

composer test

Contributing

Contributions are welcome and will be fully credited. Please see CONTRIBUTING and CONDUCT for details.

Security

If you discover any security related issues, please email nyamsprod@gmail.com instead of using the issue tracker.

Changelog

Please see CHANGELOG for more information on what has changed recently.

Credits