PHPackages                             audunru/memory-usage - 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. audunru/memory-usage

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

audunru/memory-usage
====================

Log memory usage in Laravel

v5.1.1(2w ago)03.4k—2.2%[1 PRs](https://github.com/audunru/memory-usage/pulls)MITPHPPHP ^8.3CI passing

Since Jan 16Pushed 5d ago1 watchersCompare

[ Source](https://github.com/audunru/memory-usage)[ Packagist](https://packagist.org/packages/audunru/memory-usage)[ RSS](/packages/audunru-memory-usage/feed)WikiDiscussions main Synced today

READMEChangelog (10)Dependencies (32)Versions (41)Used By (0)

Log Laravel Memory usage
========================

[](#log-laravel-memory-usage)

[![Build Status](https://github.com/audunru/memory-usage/actions/workflows/validate.yml/badge.svg)](https://github.com/audunru/memory-usage/actions/workflows/validate.yml)[![Coverage Status](https://camo.githubusercontent.com/fd6e25bfeaf62a50dfd15c1e72ccb9c05696e8eb9389115b44b7e75a6f541de3/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f617564756e72752f6d656d6f72792d75736167652f62616467652e7376673f6272616e63683d6d61696e)](https://coveralls.io/github/audunru/memory-usage?branch=main)

Log amount of memory used during HTTP requests. The peak memory usage in megabytes will be logged right before the response is returned.

The memory limit is configurable per request path. If you set the limit to 25 MiB for all requests, you will see something like this in your logs:

```
[2022-01-16 10:49:17] local.WARNING: Maximum memory 50.68 MiB used during request for /api/v1/companies/1/products is greater than limit of 25.00 MiB
[2022-01-16 10:49:29] local.WARNING: Maximum memory 50.39 MiB used during request for /api/v1/companies/1 is greater than limit of 25.00 MiB
[2022-01-16 10:49:29] local.WARNING: Maximum memory 60.04 MiB used during request for /api/v1/companies/1/sales is greater than limit of 25.00 MiB

```

Since v0.3.0 you can also log slow responses. If you set the limit to 3 seconds, you you will see something like this in your logs:

```
[2022-01-16 10:49:17] local.WARNING: Response time 5.15 s for /api/v1/companies/1/products is greater than limit of 3.00 s

```

Installation
============

[](#installation)

Step 1: Install with Composer
-----------------------------

[](#step-1-install-with-composer)

```
composer require audunru/memory-usage
```

Configuration
=============

[](#configuration)

Publish the configuration file by running:

```
php artisan vendor:publish --tag=memory-usage-config
```

Please open up the configuration file for further instructions on how to configure logging.

Development
===========

[](#development)

Testing
-------

[](#testing)

Run tests:

```
composer test
```

###  Health Score

56

—

FairBetter than 97% of packages

Maintenance99

Actively maintained with recent releases

Popularity21

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity77

Established project with proven stability

 Bus Factor2

2 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 ~57 days

Total

29

Last Release

14d ago

Major Versions

v0.5.0 → v1.0.02023-07-18

v1.0.1 → v2.0.02024-04-07

v2.0.8 → v3.0.02025-03-16

v3.0.0 → v4.0.02025-03-22

v4.0.5 → v13.x-dev2026-03-24

PHP version history (4 changes)v0.1.0PHP ^8.0

v1.0.0PHP ^8.1

v2.0.0PHP ^8.2

v13.x-devPHP ^8.3

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/5163790?v=4)[Audun Rundberg](/maintainers/audunru)[@audunru](https://github.com/audunru)

---

Top Contributors

[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (53 commits)")[![audunru](https://avatars.githubusercontent.com/u/5163790?v=4)](https://github.com/audunru "audunru (51 commits)")[![github-actions[bot]](https://avatars.githubusercontent.com/in/15368?v=4)](https://github.com/github-actions[bot] "github-actions[bot] (15 commits)")[![semantic-release-bot](https://avatars.githubusercontent.com/u/32174276?v=4)](https://github.com/semantic-release-bot "semantic-release-bot (4 commits)")

---

Tags

laraveldebugmemoryusage

###  Code Quality

TestsPHPUnit

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/audunru-memory-usage/health.svg)

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

###  Alternatives

[fruitcake/laravel-telescope-toolbar

Toolbar for Laravel Telescope based on Symfony Web Profiler

8041.7M5](/packages/fruitcake-laravel-telescope-toolbar)[stephenjude/filament-debugger

About

104162.2k2](/packages/stephenjude-filament-debugger)[api-platform/laravel

API Platform support for Laravel

58171.4k14](/packages/api-platform-laravel)[rawilk/profile-filament-plugin

Profile &amp; MFA starter kit for filament.

3914.6k](/packages/rawilk-profile-filament-plugin)[ecotone/laravel

Ecotone for Laravel — CQRS, Event Sourcing, Sagas, Durable Workflows, and Outbox on top of Laravel Queue, via PHP attributes.

21318.6k3](/packages/ecotone-laravel)[slimani/filament-media-manager

A media manager plugin for Filament.

126.9k](/packages/slimani-filament-media-manager)

PHPackages © 2026

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