PHPackages                             freshbitsweb/laravel-log-enhancer - 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. freshbitsweb/laravel-log-enhancer

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

freshbitsweb/laravel-log-enhancer
=================================

Make debugging easier by adding more data to your laravel logs

v2.1.0(1mo ago)346569.0k—6.1%33MITPHPPHP ^7.3|^8.0CI passing

Since Mar 27Pushed 2mo ago8 watchersCompare

[ Source](https://github.com/freshbitsweb/laravel-log-enhancer)[ Packagist](https://packagist.org/packages/freshbitsweb/laravel-log-enhancer)[ RSS](/packages/freshbitsweb-laravel-log-enhancer/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (8)Versions (19)Used By (0)

[![Latest Stable Version](https://camo.githubusercontent.com/4d7523c9e3e261f0c0a830e8a88407456582c45dc3447f2b32d431bb09a179dd/68747470733a2f2f706f7365722e707567782e6f72672f6672657368626974737765622f6c61726176656c2d6c6f672d656e68616e6365722f762f737461626c65)](https://packagist.org/packages/freshbitsweb/laravel-log-enhancer)[![Total Downloads](https://camo.githubusercontent.com/0b1cdd964d7867f5b7cad0c7e0863b48e32d297d5bcaa0b2110a155a0152cc04/68747470733a2f2f706f7365722e707567782e6f72672f6672657368626974737765622f6c61726176656c2d6c6f672d656e68616e6365722f646f776e6c6f616473)](https://packagist.org/packages/freshbitsweb/laravel-log-enhancer)[![License](https://camo.githubusercontent.com/be26d19d40b1c89674ac40aaf88f1256130f53d7fea8551ec1d1103195b8488b/68747470733a2f2f706f7365722e707567782e6f72672f6672657368626974737765622f6c61726176656c2d6c6f672d656e68616e6365722f6c6963656e7365)](https://packagist.org/packages/freshbitsweb/laravel-log-enhancer)[![StyleCI](https://camo.githubusercontent.com/629b25c498be3fde46a4852c3f0e72e2c865b5c469c758cd35ec0bf586913446/68747470733a2f2f7374796c6563692e696f2f7265706f732f3132363937303336392f736869656c643f6272616e63683d6d6173746572)](https://styleci.io/repos/126970369)[![Buy us a tree](https://camo.githubusercontent.com/dd118003b5a1a1654809a5c3915a5f9e213a16eeeb09781e1c5e0fe4c336f46b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4275792532306d6525323061253230747265652d2546302539462538432542332d6c69676874677265656e3f7374796c653d666c61742d737175617265)](https://plant.treeware.earth/freshbitsweb/laravel-log-enhancer)

Laravel Log Enhancer (Laravel 5.6 to Laravel 12.x)
==================================================

[](#laravel-log-enhancer-laravel-56-to-laravel-12x)

Laravel logs help all of us debug issues. We value them the most in production. But, the contextual data of the request is not logged by default. We need more than just *stack trace* to debug the issue easily. The things like **request URL**, **request input data**, **session data**, etc. help us hunt down the exact cause quickly. That's what this *plug-and-play* Laravel package does for you :)

Before
------

[](#before)

[![Before](./images/before.png "Before")](./images/before.png)

After
-----

[](#after)

[![After](./images/after.png "After")](./images/after.png)

Requirements
------------

[](#requirements)

PHPLaravelPackage8.2+12.xv2.0.08.2+11.xv1.7.08.1+10.xv1.6.08.0+9.xv1.5.08.0+9.xv1.4.07.3+8.xv1.3.07.2.5+7.xv1.2.0&lt;7.2.56.xv1.1.0&lt;7.15.xv1.0.\***Notes**:

- For Laravel 5.5, you may use [Slack Error Notifier](https://github.com/freshbitsweb/slack-error-notifier) package.

Installation
------------

[](#installation)

1. Install the package by running this command in your terminal/cmd:

```
composer require freshbitsweb/laravel-log-enhancer

```

2. Add this package's LogEnhancer class to the tap option of your log channel in **config/logging.php**:

```
'production_stack' => [
    'driver' => 'stack',
    'tap' => [Freshbitsweb\LaravelLogEnhancer\LogEnhancer::class],
    'channels' => ['daily', 'slack'],
],

```

Optionally, you can import config file by running this command in your terminal/cmd:

```
php artisan vendor:publish --tag=laravel-log-enhancer-config

```

It has following configuration settings:

- (bool) log\_request\_details =&gt; Set to *true* if you wish to log request data. [Reference](https://github.com/Seldaek/monolog/blob/master/src/Monolog/Processor/WebProcessor.php)
- (bool) log\_input\_data =&gt; Set to *true* if you wish to log user input data
- (bool) log\_request\_headers =&gt; Set to *true* if you wish to log request headers
- (bool) log\_session\_data =&gt; Set to *true* if you wish to log session data
- (bool) log\_memory\_usage =&gt; Set to *true* if you wish to log memory usage [Reference](https://github.com/Seldaek/monolog/blob/master/src/Monolog/Processor/MemoryUsageProcessor.php)
- (bool) log\_git\_data =&gt; Set to *true* if you wish to log git branch name, last commit message, last commit id, staged or (un)staged changes.
- (bool) log\_app\_details =&gt; Set to *true* if you wish to log application data. It will include Laravel Version, PHP Version, Config Cached and Route Cached details.
- (array) ignore\_input\_fields =&gt; If input data is being sent, you can specify the inputs from the user that should not be logged. for example, password,cc number, etc.

Lumen compatibility
-------------------

[](#lumen-compatibility)

We do not use Lumen in any of our projects. And this package is not tested with Lumen framework. If you are [willing](https://github.com/freshbitsweb/laravel-log-enhancer/issues/15) [to](https://github.com/freshbitsweb/laravel-log-enhancer/issues/16) use this package with Lumen, please help us by testing and making a PR to make it work. Thanks.

Authors
-------

[](#authors)

- [**Gaurav Makhecha**](https://github.com/gauravmak) - *Initial work*

See also the list of [contributors](https://github.com/freshbitsweb/laravel-log-enhancer/graphs/contributors) who participated in this project.

License
-------

[](#license)

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details

Treeware
--------

[](#treeware)

You're free to use this package, but if it makes it to your production environment I would highly appreciate you buying the world a tree.

It’s now common knowledge that one of the best tools to tackle the climate crisis and keep our temperatures from rising above 1.5C is to [plant trees](https://www.bbc.co.uk/news/science-environment-48870920). If you contribute to our forest you’ll be creating employment for local families and restoring wildlife habitats.

You can buy trees at for our forest here [offset.earth/treeware](https://plant.treeware.earth/freshbitsweb/laravel-log-enhancer)

Read more about Treeware at [treeware.earth](http://treeware.earth)

Special Thanks to
-----------------

[](#special-thanks-to)

- [Laravel](https://laravel.com) Community

###  Health Score

66

—

FairBetter than 99% of packages

Maintenance88

Actively maintained with recent releases

Popularity57

Moderate usage in the ecosystem

Community23

Small or concentrated contributor base

Maturity77

Established project with proven stability

 Bus Factor1

Top contributor holds 80.9% 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 ~182 days

Recently: every ~370 days

Total

17

Last Release

58d ago

Major Versions

v1.7.0 → v2.0.02025-02-26

PHP version history (4 changes)v1.0.0PHP &gt;=7.1.3

v1.1.0PHP ^7.2

v1.3.0PHP ^7.3

v1.3.1PHP ^7.3|^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/2628a8e3bd55b2ab1a2b4aaccb5a88d33854348c7a7d99e4f76f49c502692329?d=identicon)[gauravmak](/maintainers/gauravmak)

---

Top Contributors

[![gauravmak](https://avatars.githubusercontent.com/u/11887260?v=4)](https://github.com/gauravmak "gauravmak (55 commits)")[![eduardlleshi](https://avatars.githubusercontent.com/u/6278258?v=4)](https://github.com/eduardlleshi "eduardlleshi (4 commits)")[![laravel-shift](https://avatars.githubusercontent.com/u/15991828?v=4)](https://github.com/laravel-shift "laravel-shift (3 commits)")[![mnastalski](https://avatars.githubusercontent.com/u/10223434?v=4)](https://github.com/mnastalski "mnastalski (1 commits)")[![repat](https://avatars.githubusercontent.com/u/516807?v=4)](https://github.com/repat "repat (1 commits)")[![djallits](https://avatars.githubusercontent.com/u/10674226?v=4)](https://github.com/djallits "djallits (1 commits)")[![StyleCIBot](https://avatars.githubusercontent.com/u/11048387?v=4)](https://github.com/StyleCIBot "StyleCIBot (1 commits)")[![google-labs-jules[bot]](https://avatars.githubusercontent.com/in/842251?v=4)](https://github.com/google-labs-jules[bot] "google-labs-jules[bot] (1 commits)")[![hirenkeraliya](https://avatars.githubusercontent.com/u/22992703?v=4)](https://github.com/hirenkeraliya "hirenkeraliya (1 commits)")

---

Tags

error-reportinglaravellaravel-5-packageloggingphpphp7

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/freshbitsweb-laravel-log-enhancer/health.svg)

```
[![Health](https://phpackages.com/badges/freshbitsweb-laravel-log-enhancer/health.svg)](https://phpackages.com/packages/freshbitsweb-laravel-log-enhancer)
```

###  Alternatives

[illuminate/log

The Illuminate Log package.

6224.3M518](/packages/illuminate-log)[honeybadger-io/honeybadger-laravel

Honeybadger Laravel integration

431.2M](/packages/honeybadger-io-honeybadger-laravel)[ytake/laravel-fluent-logger

fluent logger for laravel and lumen

63541.6k1](/packages/ytake-laravel-fluent-logger)[kitloong/laravel-app-logger

Laravel log for your application

101.2M8](/packages/kitloong-laravel-app-logger)[shaffe/laravel-mail-log-channel

A package to support logging via email in Laravel

1286.2k](/packages/shaffe-laravel-mail-log-channel)[label84/laravel-auth-log

Log user authentication actions in Laravel.

3654.0k](/packages/label84-laravel-auth-log)

PHPackages © 2026

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