PHPackages                             danharrin/livewire-rate-limiting - 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. danharrin/livewire-rate-limiting

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

danharrin/livewire-rate-limiting
================================

Apply rate limiters to Laravel Livewire actions.

v2.2.0(2mo ago)40523.1M—1.3%2820MITPHPPHP ^8.0CI passing

Since Jan 17Pushed 4d ago5 watchersCompare

[ Source](https://github.com/danharrin/livewire-rate-limiting)[ Packagist](https://packagist.org/packages/danharrin/livewire-rate-limiting)[ Docs](https://github.com/danharrin/livewire-rate-limiting)[ GitHub Sponsors](https://github.com/danharrin)[ RSS](/packages/danharrin-livewire-rate-limiting/feed)WikiDiscussions 2.x Synced 1mo ago

READMEChangelog (10)Dependencies (10)Versions (15)Used By (20)

 [![Package banner](https://user-images.githubusercontent.com/41773797/104827274-ddb3a580-5853-11eb-9d53-eaf3e7776734.png)](https://user-images.githubusercontent.com/41773797/104827274-ddb3a580-5853-11eb-9d53-eaf3e7776734.png)

 [![Tests passing](https://camo.githubusercontent.com/75cd9700550be01374c306fd21973ab75e4080add5f6cbd953ec3aa75ec9b3e7/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f54657374732d70617373696e672d677265656e3f7374796c653d666f722d7468652d6261646765266c6f676f3d676974687562)](https://github.com/danharrin/livewire-rate-limiting/actions) [![Laravel v9.x, v10.x, v11.x, v12.x, v13.x](https://camo.githubusercontent.com/2afc181a9835fa4c80621a2af8171a0ff983fad0e81e8b0abdab4fe158185204/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c61726176656c2d76392e782c207631302e782c207631312e782c207631322e782c207631332e782d4646324432303f7374796c653d666f722d7468652d6261646765266c6f676f3d6c61726176656c)](https://laravel.com) [![PHP 8.0+](https://camo.githubusercontent.com/f8ae9b095ead64e43e39c9fddc8a45476982edeb847452307f7baf6294b326a8/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e302b2d3737374242343f7374796c653d666f722d7468652d6261646765266c6f676f3d706870)](https://laravel.com)

This package allows you to apply rate limiters to Laravel Livewire actions. This is useful for throttling login attempts and other brute force attacks, reducing spam, and more.

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

[](#installation)

You can use Composer to install this package into your application:

```
composer require danharrin/livewire-rate-limiting

```

This package requires at least Laravel v8.x, when rate limiting improvements were introduced.

This package is tested to support the `file` and `redis` cache drivers, but not `array`.

Usage
-----

[](#usage)

Apply the `DanHarrin\LivewireRateLimiting\WithRateLimiting` trait to your Livewire component:

```
