PHPackages                             webikevn/query-logger - 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. webikevn/query-logger

ActiveLibrary

webikevn/query-logger
=====================

A dev tool to log all queries for laravel application.

1.0(5y ago)03MITPHP

Since Sep 29Pushed 5y ago1 watchersCompare

[ Source](https://github.com/webikevn/query-logger)[ Packagist](https://packagist.org/packages/webikevn/query-logger)[ RSS](/packages/webikevn-query-logger/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (1)Dependencies (1)Versions (2)Used By (0)

 Query Logger
==============

[](#-query-logger-)

 📝 A dev tool to log all queries for Laravel application.

Installing
----------

[](#installing)

```
$ composer require webikevn/query-logger --dev
```

Query Logger will be enabled when `LOG_QUERY` is `true`.

> Please keep the `--dev` option.

Usage
-----

[](#usage)

```
$ tail -f ./storage/logs/laravel.log
```

```
[2017-09-05 14:52:14] local.DEBUG: [800μs] select count(*) as aggregate from `discussions` where `discussions`.`deleted_at` is null | GET: http://laravel.app/discussions
[2017-09-05 14:52:14] local.DEBUG: [1.07ms] select * from `discussions` where `discussions`.`deleted_at` is null order by `is_top` desc, `created_at` desc limit 15 offset 0 | GET: http://laravel.app/discussions
[2017-09-05 14:52:14] local.DEBUG: [3.63s] select `tags`.*, `taggables`.`taggable_id` as `pivot_taggable_id`, `taggables`.`tag_id` as `pivot_tag_id` from `tags` inner join `taggables` on `tags`.`id` = `taggables`.`tag_id` where `taggables`.`taggable_id` in ('1', '2', '3', '4', '5', '6', '7', '8') and `taggables`.`taggable_type` = 'App\\Models\\Discussion' order by `order_column` asc | GET: http://laravel.app/discussions
[2017-09-05 14:52:14] local.DEBUG: [670μs] select * from `users` where `users`.`id` in ('1', '2', '4') and `users`.`deleted_at` is null | GET: http://laravel.app/discussions
...

```

### Configuration

[](#configuration)

If you want to use it in a environment, you can control whether or not to log a query via the configuration file：

*config/logging.php:*

```
return [
    //...
    'query' => [
        'enabled' => env('LOG_QUERY', false),

        // Only record queries that are slower than the following time
        // Unit: milliseconds
        'slower_than' => 0,
    ],
];
```

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity54

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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

Unknown

Total

1

Last Release

2057d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/09f7d0bae763e995aa8b55c06da4a631819fc5e7acf10f1aa4a17e1ea8ab0fd8?d=identicon)[giangbeoit](/maintainers/giangbeoit)

---

Top Contributors

[![GiangBeo](https://avatars.githubusercontent.com/u/3804842?v=4)](https://github.com/GiangBeo "GiangBeo (3 commits)")

### Embed Badge

![Health badge](/badges/webikevn-query-logger/health.svg)

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

###  Alternatives

[anourvalar/eloquent-serialize

Laravel Query Builder (Eloquent) serialization

11120.2M21](/packages/anourvalar-eloquent-serialize)[namu/wirechat

A Laravel Livewire messaging app for teams with private chats and group conversations.

54324.5k](/packages/namu-wirechat)[statamic-rad-pack/runway

Eloquently manage your database models in Statamic.

135192.6k5](/packages/statamic-rad-pack-runway)

PHPackages © 2026

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