PHPackages                             lotfio/ouch - 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. lotfio/ouch

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

lotfio/ouch
===========

Ouch Error handler for PHP

0.3.1(6y ago)2326451MITPHPPHP ^7.2CI failing

Since Mar 30Pushed 5y ago6 watchersCompare

[ Source](https://github.com/lotfio/ouch)[ Packagist](https://packagist.org/packages/lotfio/ouch)[ RSS](/packages/lotfio-ouch/feed)WikiDiscussions master Synced 2d ago

READMEChangelog (6)Dependencies (1)Versions (10)Used By (1)

Ouch error handler for PHP
==========================

[](#ouch-error-handler-for-php)

[![ouch](https://user-images.githubusercontent.com/18489496/36539671-dbf89a76-17d7-11e8-99e1-b372935b83c4.png)](https://user-images.githubusercontent.com/18489496/36539671-dbf89a76-17d7-11e8-99e1-b372935b83c4.png)

About Ouch :
------------

[](#about-ouch-)

Ouch is simple and lightweight ErrorHandler for PHP. It is aimed to help you debug PHP errors in a nice and detailed way. ouch is the Offical @SilverEngine framework error handler.

[![licence](https://camo.githubusercontent.com/55fb3ccc1135120fec87457ec8f2f7dbf923a73b30d6a3b11fc14a0d58e9389a/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e63652d4d49542d79656c6c6f772e737667)](https://camo.githubusercontent.com/55fb3ccc1135120fec87457ec8f2f7dbf923a73b30d6a3b11fc14a0d58e9389a/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e63652d4d49542d79656c6c6f772e737667)[![language](https://camo.githubusercontent.com/d23ce60b89c28c023d0ca69981ec9afbb17eb08a9cd1b609fd84c15d0732b7ce/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d372d626c75652e737667)](https://camo.githubusercontent.com/d23ce60b89c28c023d0ca69981ec9afbb17eb08a9cd1b609fd84c15d0732b7ce/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d372d626c75652e737667)[![version](https://camo.githubusercontent.com/470814095c730e214d01bbf479aec1935493db35e82037bbec89f83473f0ed28/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f56657273696f6e2d302e332e312d7265642e737667)](https://camo.githubusercontent.com/470814095c730e214d01bbf479aec1935493db35e82037bbec89f83473f0ed28/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f56657273696f6e2d302e332e312d7265642e737667)[![coverage](https://camo.githubusercontent.com/84d2a2053a4d1dbd6248c18456ee7d635a8c681f0ced03ed46ea337b9a657918/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f636f7665726167652d33302532352d626c75652e737667)](https://camo.githubusercontent.com/84d2a2053a4d1dbd6248c18456ee7d635a8c681f0ced03ed46ea337b9a657918/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f636f7665726167652d33302532352d626c75652e737667)[![build](https://camo.githubusercontent.com/bce6b0a93b8d4f27ea7df675f4fd2dcc20d4218dd59ee7b1bd1c4f52ec38c2a7/68747470733a2f2f7472617669732d63692e6f72672f6c6f7466696f2f6f7563682e7376673f6272616e63683d646576656c6f70)](https://camo.githubusercontent.com/bce6b0a93b8d4f27ea7df675f4fd2dcc20d4218dd59ee7b1bd1c4f52ec38c2a7/68747470733a2f2f7472617669732d63692e6f72672f6c6f7466696f2f6f7563682e7376673f6272616e63683d646576656c6f70)[![StyleCI](https://camo.githubusercontent.com/71bda707838a2f946506e8b68e7fd4e37f175403c61812545b00cc9deec9e6be/68747470733a2f2f6769746875622e7374796c6563692e696f2f7265706f732f3131373539393932372f736869656c643f6272616e63683d646576656c6f70)](https://github.styleci.io/repos/117599927)

How it looks like :
-------------------

[](#how-it-looks-like-)

### HTTP

[](#http)

[![http-error](https://github.com/lotfio/ouch/raw/develop/docs/ouch.png)](https://github.com/lotfio/ouch/blob/develop/docs/ouch.png)

### CLI

[](#cli)

[![cli-error](https://github.com/lotfio/ouch/raw/develop/docs/console.png)](https://github.com/lotfio/ouch/blob/develop/docs/console.png)

Features :
----------

[](#features-)

- Simple and easy to use.
- Transforms all errors to Exceptions.
- Catches all Errors and Exceptions.
- Catches Fatal Errors.
- Displays friendly Html errors.
- Displays friendly console (CLI) errors.
- Zero errors in prduction.

Instalation &amp; Use :
=======================

[](#instalation--use-)

```
    composer require lotfio/ouch
```

### Use it:

[](#use-it)

```
    $ouch = new Ouch\Ouch;
    $ouch->enableErrorHandler($env = 'pro'); // for development use $env = 'dev';
```

Contributing
------------

[](#contributing)

Thank you for considering to contribute to Ouch. All the contribution guidelines are mentioned [here](CONTRIBUTE.md).

ChangeLog
---------

[](#changelog)

Here you can find the [ChangeLog](CHANGELOG.md).

Support the development
-----------------------

[](#support-the-development)

Share **Ouch** and lets get more stars and more contributors.

License
-------

[](#license)

***Ouch*** is an open-source software licensed under the [MIT license](LICENSE).

###  Health Score

31

—

LowBetter than 66% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity24

Limited adoption so far

Community18

Small or concentrated contributor base

Maturity54

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 98.7% of commits — single point of failure

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 ~131 days

Recently: every ~182 days

Total

7

Last Release

2229d ago

Major Versions

0.1.7 → 5.6.x-dev2018-10-05

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/18489496?v=4)[lotfio lakehal](/maintainers/lotfio)[@lotfio](https://github.com/lotfio)

---

Top Contributors

[![lotfio](https://avatars.githubusercontent.com/u/18489496?v=4)](https://github.com/lotfio "lotfio (147 commits)")[![Nejcc](https://avatars.githubusercontent.com/u/6236128?v=4)](https://github.com/Nejcc "Nejcc (1 commits)")[![peter279k](https://avatars.githubusercontent.com/u/9021747?v=4)](https://github.com/peter279k "peter279k (1 commits)")

---

Tags

error-handlererror-monitoringerror-reportingphp

###  Code Quality

TestsPHPUnit

### Embed Badge

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

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

###  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)
