PHPackages                             chrisdowson/xhprof - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Debugging &amp; Profiling](/categories/debugging)
4. /
5. chrisdowson/xhprof

ActiveLibrary[Debugging &amp; Profiling](/categories/debugging)

chrisdowson/xhprof
==================

XHProf: A Hierarchical Profiler for PHP

v1.0.0(2y ago)04BSD-3-ClausePHP

Since Aug 16Pushed 2y agoCompare

[ Source](https://github.com/Chrisdowson/xhprof)[ Packagist](https://packagist.org/packages/chrisdowson/xhprof)[ RSS](/packages/chrisdowson-xhprof/feed)WikiDiscussions php7 Synced today

READMEChangelog (1)DependenciesVersions (2)Used By (0)

Maintained xhprof for PHP 7.0, 7.1, 7.2 and 7.3
===============================================

[](#maintained-xhprof-for-php-70-71-72-and-73)

Install
-------

[](#install)

### Compile in Linux

[](#compile-in-linux)

```
$ cd extension/
$ phpize
$ ./configure [--with-php-config=/path/to/php-config]
$ make && make install

```

edit php.ini, add a new line:

```
extension=xhprof.so

```

make sure it works:

```
php -m |grep xhprof

```

Profile your page
-----------------

[](#profile-your-page)

Add the following, as early as possible, to your initial PHP script:

```
xhprof_enable();

register_shutdown_function(
    function () {
        file_put_contents("/tmp/" . uniqid() . ".ApplicationName.xhprof", serialize(xhprof_disable()));
    }
);
```

Look at the results:
--------------------

[](#look-at-the-results)

Make sure `xhprof_html` directory is reachable from your web application and reach the page `xhprof_html/index.php` to see a list of profiles.

###  Health Score

22

—

LowBetter than 21% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community18

Small or concentrated contributor base

Maturity44

Maturing project, gaining track record

 Bus Factor3

3 contributors hold 50%+ of commits

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

1051d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/6045803?v=4)[段小强](/maintainers/Chrisdowson)[@Chrisdowson](https://github.com/Chrisdowson)

---

Top Contributors

[![billf](https://avatars.githubusercontent.com/u/265988?v=4)](https://github.com/billf "billf (17 commits)")[![patrickallaert](https://avatars.githubusercontent.com/u/195277?v=4)](https://github.com/patrickallaert "patrickallaert (12 commits)")[![scottmac](https://avatars.githubusercontent.com/u/50088?v=4)](https://github.com/scottmac "scottmac (4 commits)")[![Rarst](https://avatars.githubusercontent.com/u/737584?v=4)](https://github.com/Rarst "Rarst (3 commits)")[![c9s](https://avatars.githubusercontent.com/u/50894?v=4)](https://github.com/c9s "c9s (3 commits)")[![martinsupiot](https://avatars.githubusercontent.com/u/19933642?v=4)](https://github.com/martinsupiot "martinsupiot (2 commits)")[![robocoder](https://avatars.githubusercontent.com/u/922051?v=4)](https://github.com/robocoder "robocoder (2 commits)")[![davidsklar](https://avatars.githubusercontent.com/u/177495?v=4)](https://github.com/davidsklar "davidsklar (2 commits)")[![erikwebb](https://avatars.githubusercontent.com/u/372194?v=4)](https://github.com/erikwebb "erikwebb (2 commits)")[![jwpage](https://avatars.githubusercontent.com/u/52687?v=4)](https://github.com/jwpage "jwpage (1 commits)")[![NoUseFreak](https://avatars.githubusercontent.com/u/879864?v=4)](https://github.com/NoUseFreak "NoUseFreak (1 commits)")[![oliworx](https://avatars.githubusercontent.com/u/1712684?v=4)](https://github.com/oliworx "oliworx (1 commits)")[![Provoker](https://avatars.githubusercontent.com/u/5089984?v=4)](https://github.com/Provoker "Provoker (1 commits)")[![remicollet](https://avatars.githubusercontent.com/u/270445?v=4)](https://github.com/remicollet "remicollet (1 commits)")[![webdevel](https://avatars.githubusercontent.com/u/1288852?v=4)](https://github.com/webdevel "webdevel (1 commits)")[![Chrisdowson](https://avatars.githubusercontent.com/u/6045803?v=4)](https://github.com/Chrisdowson "Chrisdowson (1 commits)")[![danez](https://avatars.githubusercontent.com/u/231804?v=4)](https://github.com/danez "danez (1 commits)")[![draco2003](https://avatars.githubusercontent.com/u/196891?v=4)](https://github.com/draco2003 "draco2003 (1 commits)")[![dshafik](https://avatars.githubusercontent.com/u/58074?v=4)](https://github.com/dshafik "dshafik (1 commits)")[![enumag](https://avatars.githubusercontent.com/u/539462?v=4)](https://github.com/enumag "enumag (1 commits)")

### Embed Badge

![Health badge](/badges/chrisdowson-xhprof/health.svg)

```
[![Health](https://phpackages.com/badges/chrisdowson-xhprof/health.svg)](https://phpackages.com/packages/chrisdowson-xhprof)
```

###  Alternatives

[fjogeleit/prometheus-messenger-middleware

Prometheus Middleware for the Symfony Messenger Component

2255.2k](/packages/fjogeleit-prometheus-messenger-middleware)[spatie/craft-ray

Easily debug CraftCMS projects

1638.6k](/packages/spatie-craft-ray)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
