PHPackages                             moafak/laravel-weak-etag-middleware - 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. [HTTP &amp; Networking](/categories/http)
4. /
5. moafak/laravel-weak-etag-middleware

AbandonedArchivedLibrary[HTTP &amp; Networking](/categories/http)

moafak/laravel-weak-etag-middleware
===================================

A Laravel middleware to add weak etags to HTTP response headers

v1.0.0(8y ago)011MITPHP

Since Mar 28Pushed 8y ago1 watchersCompare

[ Source](https://github.com/moafak/laravel-weak-etag-middleware)[ Packagist](https://packagist.org/packages/moafak/laravel-weak-etag-middleware)[ RSS](/packages/moafak-laravel-weak-etag-middleware/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependencies (5)Versions (2)Used By (0)

laravel-weak-etag-middleware
============================

[](#laravel-weak-etag-middleware)

A Laravel middleware for adding ***Weak ETags*** to HTTP requests to improve response times

[![Build Status](https://camo.githubusercontent.com/9129738d8c3c43a96033cdd80f1a360e3a0d97d451ec6b58b3583f315b84b81c/68747470733a2f2f7472617669732d63692e6f72672f6d6f6166616b2f6c61726176656c2d7765616b2d657461672d6d6964646c65776172652e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/moafak/laravel-weak-etag-middleware)[![Coverage Status](https://camo.githubusercontent.com/c610af7921616b624a31b4ef4bed06c3e87aab7f972a1076970d764c9c9d10af/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f6d6f6166616b2f6c61726176656c2d7765616b2d657461672d6d6964646c65776172652f62616467652e7376673f6272616e63683d6d6173746572)](https://coveralls.io/github/moafak/laravel-weak-etag-middleware?branch=master)

Weak Etag vs Strong Etag
------------------------

[](#weak-etag-vs-strong-etag)

Etag is a digest of the response content, usually with a hashing function.
Strong etag means the content of the response is byte-for-byte identical.
While weak etag means the content is symantically identical.

Example of strong etag: `"f9bba821aec5e6b4607597cb500898f7"`
Example of weak etag: `W/"f9bba821aec5e6b4607597cb500898f7"`

Refer to the [blog post](https://moafak.github.io/blog/2018/02/28/weak-etags-laravel/) for more info.

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

[](#installation)

Run the following command to install the package:

```
composer require moafak/laravel-weak-etag-middleware
```

Then just include this in your `app/Http/Kernel.php` in the appropriate place where you want to import the middleware:

```
\moafak\WeakETagMiddleware\WeakETag::class
```

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

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

2967d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0a3f91f1cb3bb8404ee8ae4a05eff2f8edddc0f5e6a51ace681690285674a256?d=identicon)[moafak](/maintainers/moafak)

---

Top Contributors

[![matthewbdaly](https://avatars.githubusercontent.com/u/450801?v=4)](https://github.com/matthewbdaly "matthewbdaly (29 commits)")[![georgehanson](https://avatars.githubusercontent.com/u/23167178?v=4)](https://github.com/georgehanson "georgehanson (1 commits)")[![moafak](https://avatars.githubusercontent.com/u/5840370?v=4)](https://github.com/moafak "moafak (1 commits)")

---

Tags

httpmiddlewarelaravelEtagweak etag

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/moafak-laravel-weak-etag-middleware/health.svg)

```
[![Health](https://phpackages.com/badges/moafak-laravel-weak-etag-middleware/health.svg)](https://phpackages.com/packages/moafak-laravel-weak-etag-middleware)
```

###  Alternatives

[matthewbdaly/laravel-etag-middleware

A Laravel middleware for adding ETags to HTTP requests to improve response times

64326.0k2](/packages/matthewbdaly-laravel-etag-middleware)[tomschlick/request-migrations

HTTP Request Migrations

1844.5k](/packages/tomschlick-request-migrations)[dragon-code/laravel-http-logger

Logging incoming HTTP requests

319.8k3](/packages/dragon-code-laravel-http-logger)[api-platform/laravel

API Platform support for Laravel

59126.4k6](/packages/api-platform-laravel)[laragear/json

Easily retrieve and manipulate `Json` across your application.

363.5k](/packages/laragear-json)[laravel-shift/curl-converter

A command line tool to convert curl requests to Laravel HTTP requests.

935.3k](/packages/laravel-shift-curl-converter)

PHPackages © 2026

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