PHPackages                             sentry/sentry - 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. [Logging &amp; Monitoring](/categories/logging)
4. /
5. sentry/sentry

ActiveLibrary[Logging &amp; Monitoring](/categories/logging)

sentry/sentry
=============

PHP SDK for Sentry (http://sentry.io)

4.23.0(1mo ago)1.9k227.1M—2.2%466[16 issues](https://github.com/getsentry/sentry-php/issues)[9 PRs](https://github.com/getsentry/sentry-php/pulls)20MITPHPPHP ^7.2|^8.0CI passing

Since Feb 1Pushed today84 watchersCompare

[ Source](https://github.com/getsentry/sentry-php)[ Packagist](https://packagist.org/packages/sentry/sentry)[ Docs](http://sentry.io)[ Fund](https://sentry.io/)[ Fund](https://sentry.io/pricing/)[ RSS](/packages/sentry-sentry/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (32)Versions (202)Used By (20)

 [ ![Sentry for PHP](https://camo.githubusercontent.com/6383fcb4aef4c8f1437bcda3e1564bed84ef4559f2daa6a502efbccf2e073097/68747470733a2f2f73656e7472792d6272616e642e73746f726167652e676f6f676c65617069732e636f6d2f6769746875622d62616e6e6572732f6769746875622d73646b2d7068702e6a7067) ](https://sentry.io/?utm_source=github&utm_medium=logo)

*Bad software is everywhere, and we're tired of it. Sentry is on a mission to help developers write better software faster, so we can get back to enjoying technology. If you want to join us [**Check out our open positions**](https://sentry.io/careers/)*

Official Sentry SDK for PHP
===========================

[](#official-sentry-sdk-for-php)

[![CI](https://github.com/getsentry/sentry-php/workflows/CI/badge.svg?branch=master)](https://github.com/getsentry/sentry-php/actions?query=workflow%3ACI+branch%3Amaster)[![Coverage Status](https://camo.githubusercontent.com/54fcd0e1fc0be84744623f64410ffaee588d62941756725cce0f3f309c655aba/68747470733a2f2f696d672e736869656c64732e696f2f636f6465636f762f632f6769746875622f67657473656e7472792f73656e7472792d7068702f6d61737465723f6c6f676f3d636f6465636f76)](https://codecov.io/gh/getsentry/sentry-php/branch/master)[![Latest Stable Version](https://camo.githubusercontent.com/ef6790c1d440fc7515a4cda057d21a093ec6938c69d02eadccc3fc5ab67db3ff/68747470733a2f2f706f7365722e707567782e6f72672f73656e7472792f73656e7472792f762f737461626c65)](https://packagist.org/packages/sentry/sentry)[![License](https://camo.githubusercontent.com/06795fc7251edcef1f23a2dd5e0e15a51fe5c1ec8dd2a80e5a735c0986ded761/68747470733a2f2f706f7365722e707567782e6f72672f73656e7472792f73656e7472792f6c6963656e7365)](https://packagist.org/packages/sentry/sentry)[![Total Downloads](https://camo.githubusercontent.com/5d508401a00ea26c8c0cec71b9b69ac5015363d80a061d3e4b83e508747d84c5/68747470733a2f2f706f7365722e707567782e6f72672f73656e7472792f73656e7472792f646f776e6c6f616473)](https://packagist.org/packages/sentry/sentry)[![Monthly Downloads](https://camo.githubusercontent.com/c9665d35dbde6baacc0fdbe5bc0954310eda49ae26c12a3fe78f2b6f8707624f/68747470733a2f2f706f7365722e707567782e6f72672f73656e7472792f73656e7472792f642f6d6f6e74686c79)](https://packagist.org/packages/sentry/sentry)[![Discord](https://camo.githubusercontent.com/2da2973533965a9404e5ef0683e6cd8192988281f5860256076294e906b9c40c/68747470733a2f2f696d672e736869656c64732e696f2f646973636f72642f363231373738383331363032323231303634)](https://discord.gg/cWnMQeA)

The Sentry PHP error reporter tracks errors and exceptions that happen during the execution of your application and provides instant notification with detailed information needed to prioritize, identify, reproduce and fix each issue.

Getting started
---------------

[](#getting-started)

### Install

[](#install)

Install the SDK using [Composer](https://getcomposer.org/).

```
composer require sentry/sentry
```

### Configuration

[](#configuration)

Initialize the SDK as early as possible in your application.

```
\Sentry\init(['dsn' => '___PUBLIC_DSN___' ]);
```

### Usage

[](#usage)

```
try {
    thisFunctionThrows(); // -> throw new \Exception('foo bar');
} catch (\Exception $exception) {
    \Sentry\captureException($exception);
}
```

Official integrations
---------------------

[](#official-integrations)

The following integrations are fully supported and maintained by the Sentry team.

- [Symfony](https://github.com/getsentry/sentry-symfony)
- [Laravel](https://github.com/getsentry/sentry-laravel)

3rd party integrations using SDK 4.x
------------------------------------

[](#3rd-party-integrations-using-sdk-4x)

The following integrations are available and maintained by members of the Sentry community.

- [Drupal](https://www.drupal.org/project/raven)
- [WordPress](https://wordpress.org/plugins/wp-sentry-integration/)
- Magento 2 by [JustBetter](https://github.com/justbetter/magento2-sentry) or by [Mygento](https://github.com/mygento/module-sentry)
- [Joomla!](https://github.com/AlterBrains/sentry-joomla)
- Neos Flow (and CMS) using [flownative/sentry](https://github.com/flownative/flow-sentry) or [networkteam/sentryclient](https://github.com/networkteam/Networkteam.SentryClient)
- Neos CMS with specific Fusion handling using [networkteam/neos-sentryclient](https://github.com/networkteam/Netwokteam.Neos.SentryClient)
- [TYPO3](https://github.com/networkteam/sentry_client)
- ... feel free to be famous, create a port to your favourite platform!

3rd party integrations using the old SDK 3.x
--------------------------------------------

[](#3rd-party-integrations-using-the-old-sdk-3x)

- [ZendFramework](https://github.com/facile-it/sentry-module)
- [Yii2](https://github.com/notamedia/yii2-sentry)
- [Silverstripe](https://github.com/phptek/silverstripe-sentry)
- [CakePHP 3.0 - 4.3](https://github.com/Connehito/cake-sentry)
- [CakePHP 4.4+](https://github.com/lordsimal/cakephp-sentry)
- [October CMS](https://github.com/OFFLINE-GmbH/oc-sentry-plugin)

3rd party integrations using the old SDK 2.x
--------------------------------------------

[](#3rd-party-integrations-using-the-old-sdk-2x)

- [OXID eShop](https://github.com/OXIDprojects/sentry)
- [CakePHP](https://github.com/Connehito/cake-sentry/tree/3.x)

3rd party integrations using the old SDK 1.x
--------------------------------------------

[](#3rd-party-integrations-using-the-old-sdk-1x)

- [OpenCart](https://github.com/BurdaPraha/oc_sentry)
- [TYPO3](https://github.com/networkteam/sentry_client/tree/2.1.1)

Community
---------

[](#community)

- [Documentation](https://docs.sentry.io/error-reporting/quickstart/?platform=php)
- [Bug Tracker](http://github.com/getsentry/sentry-php/issues)
- [Code](http://github.com/getsentry/sentry-php)

Contributing to the SDK
-----------------------

[](#contributing-to-the-sdk)

Please make sure to read the [CONTRIBUTING.md](CONTRIBUTING.md) before making a pull request.

Thanks to everyone who has contributed to this project so far.

[ ![](https://camo.githubusercontent.com/d45aa8f172935204c9d0380e9860b7c41a424d53d7257db36ce280d42e1be035/68747470733a2f2f636f6e7472696275746f72732d696d672e7765622e6170702f696d6167653f7265706f3d67657473656e7472792f73656e7472792d706870)](https://github.com/getsentry/sentry-php/graphs/contributors)Getting help/support
--------------------

[](#getting-helpsupport)

If you need help setting up or configuring the PHP SDK (or anything else in the Sentry universe) please head over to the [Sentry Community on Discord](https://discord.com/invite/sentry). There is a ton of great people in our Discord community ready to help you!

Resources
---------

[](#resources)

- [![Documentation](https://camo.githubusercontent.com/89b631a7c9f547c7fff1464870c5b11aad560fe0cc1114774e8ea5addbc69f9e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f646f63756d656e746174696f6e2d73656e7472792e696f2d677265656e2e737667)](https://docs.sentry.io/quickstart/)
- [![Discord](https://camo.githubusercontent.com/2da2973533965a9404e5ef0683e6cd8192988281f5860256076294e906b9c40c/68747470733a2f2f696d672e736869656c64732e696f2f646973636f72642f363231373738383331363032323231303634)](https://discord.gg/Ww9hbqr)
- [![Stack Overflow](https://camo.githubusercontent.com/e69d3e4fed2234d76f0ebb262dc944f4abdf903ae1fea7688de7a3183ae42a49/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f737461636b2532306f766572666c6f772d73656e7472792d677265656e2e737667)](http://stackoverflow.com/questions/tagged/sentry)
- [![X Follow](https://camo.githubusercontent.com/e11a6ee45c3be7e08fcf505154c42d5aeded64de7ef97ee539a3d9f96e211a41/68747470733a2f2f696d672e736869656c64732e696f2f747769747465722f666f6c6c6f772f73656e7472793f6c6162656c3d73656e747279267374796c653d736f6369616c)](https://x.com/intent/follow?screen_name=sentry)

License
-------

[](#license)

Licensed under the MIT license, see [`LICENSE`](LICENSE)

###  Health Score

84

—

ExcellentBetter than 100% of packages

Maintenance95

Actively maintained with recent releases

Popularity83

Widely adopted with strong download metrics

Community59

Growing community involvement

Maturity88

Battle-tested with a long release history

 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

Every ~30 days

Recently: every ~8 days

Total

169

Last Release

57d ago

Major Versions

2.5.2 → 3.1.52021-02-18

1.x-dev → 3.2.22021-05-06

3.22.0 → 4.0.02023-11-06

3.x-dev → 4.0.12023-11-13

4.22.0 → 5.x-dev2026-03-18

PHP version history (5 changes)0.1PHP &gt;=5.2.4

1.7.0PHP ^5.3|^7.0

2.0.0-beta1PHP ^7.1

3.0.0PHP ^7.2

3.1.1PHP ^7.2|^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/122e44894684040bbecb610a52805f7bfd3ee5f27e644183c10ffc73df23ee17?d=identicon)[zeeg](/maintainers/zeeg)

![](https://www.gravatar.com/avatar/fe5ccdddb1a96018b48de2d474f6d253228ab68304d3a5ebfbdccfc8f341e027?d=identicon)[HazAT](/maintainers/HazAT)

![](https://www.gravatar.com/avatar/073f050f44e9fae015e8f5beffbe0001382b62ed410998af6acb9665626b51e6?d=identicon)[Sentry](/maintainers/Sentry)

---

Top Contributors

[![dcramer](https://avatars.githubusercontent.com/u/23610?v=4)](https://github.com/dcramer "dcramer (580 commits)")[![cleptric](https://avatars.githubusercontent.com/u/6617432?v=4)](https://github.com/cleptric "cleptric (227 commits)")[![ste93cry](https://avatars.githubusercontent.com/u/1770485?v=4)](https://github.com/ste93cry "ste93cry (196 commits)")[![stayallive](https://avatars.githubusercontent.com/u/1090754?v=4)](https://github.com/stayallive "stayallive (109 commits)")[![Jean85](https://avatars.githubusercontent.com/u/6729988?v=4)](https://github.com/Jean85 "Jean85 (104 commits)")[![HazAT](https://avatars.githubusercontent.com/u/363802?v=4)](https://github.com/HazAT "HazAT (89 commits)")[![Litarnus](https://avatars.githubusercontent.com/u/8436563?v=4)](https://github.com/Litarnus "Litarnus (66 commits)")[![nokitakaze](https://avatars.githubusercontent.com/u/9131758?v=4)](https://github.com/nokitakaze "nokitakaze (54 commits)")[![getsentry-bot](https://avatars.githubusercontent.com/u/10587625?v=4)](https://github.com/getsentry-bot "getsentry-bot (54 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (37 commits)")[![localheinz](https://avatars.githubusercontent.com/u/605483?v=4)](https://github.com/localheinz "localheinz (17 commits)")[![mvantellingen](https://avatars.githubusercontent.com/u/245297?v=4)](https://github.com/mvantellingen "mvantellingen (11 commits)")[![mabrahamde](https://avatars.githubusercontent.com/u/1302147?v=4)](https://github.com/mabrahamde "mabrahamde (9 commits)")[![GromNaN](https://avatars.githubusercontent.com/u/400034?v=4)](https://github.com/GromNaN "GromNaN (9 commits)")[![jeromemacias](https://avatars.githubusercontent.com/u/582446?v=4)](https://github.com/jeromemacias "jeromemacias (9 commits)")[![stephanie-anderson](https://avatars.githubusercontent.com/u/7096858?v=4)](https://github.com/stephanie-anderson "stephanie-anderson (9 commits)")[![mfb](https://avatars.githubusercontent.com/u/3278?v=4)](https://github.com/mfb "mfb (9 commits)")[![AD7six](https://avatars.githubusercontent.com/u/33387?v=4)](https://github.com/AD7six "AD7six (8 commits)")[![mitsuhiko](https://avatars.githubusercontent.com/u/7396?v=4)](https://github.com/mitsuhiko "mitsuhiko (7 commits)")[![msabramo](https://avatars.githubusercontent.com/u/305268?v=4)](https://github.com/msabramo "msabramo (7 commits)")

---

Tags

crash-reportingcrash-reportserror-handlererror-monitoringhacktoberfestphpsdksentrysentry-clienttag-productionteam-web-backendlogloggingprofilingtracingsentryerror-handlererror-monitoringcrash-reportingcrash-reports

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan, Psalm

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

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

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

###  Alternatives

[sentry/sentry-laravel

Laravel SDK for Sentry (https://sentry.io)

1.3k114.3M154](/packages/sentry-sentry-laravel)[sentry/sdk

This is a meta package of sentry/sentry. We recommend using sentry/sentry directly.

328134.8M151](/packages/sentry-sdk)[stayallive/wp-sentry

A (unofficial) WordPress plugin to report PHP and JavaScript errors to Sentry.

379197.9k](/packages/stayallive-wp-sentry)[open-telemetry/api

API for OpenTelemetry PHP.

1933.0M214](/packages/open-telemetry-api)

PHPackages © 2026

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