PHPackages                             mattitjaab/laravel-plausible-proxy - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. mattitjaab/laravel-plausible-proxy

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

mattitjaab/laravel-plausible-proxy
==================================

A Laravel package for proxying Plausible Analytics, improving performance and privacy.

v1.5(10mo ago)0276[1 issues](https://github.com/MattitjaAB/laravel-plausible-proxy/issues)[4 PRs](https://github.com/MattitjaAB/laravel-plausible-proxy/pulls)MITPHPPHP ^8.3CI passing

Since Jan 30Pushed 1mo agoCompare

[ Source](https://github.com/MattitjaAB/laravel-plausible-proxy)[ Packagist](https://packagist.org/packages/mattitjaab/laravel-plausible-proxy)[ Docs](https://github.com/mattitjaab/laravel-plausible-proxy)[ GitHub Sponsors]()[ RSS](/packages/mattitjaab-laravel-plausible-proxy/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (6)Dependencies (13)Versions (11)Used By (0)

laravel-plausible-proxy
=======================

[](#laravel-plausible-proxy)

[![Latest Version on Packagist](https://camo.githubusercontent.com/a2be62d0b44c42a0891694fd218b97d7439ba78a8c0a664eafb994f263354b9c/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6d61747469746a6161622f6c61726176656c2d706c61757369626c652d70726f78792e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/mattitjaab/laravel-plausible-proxy)[![GitHub Tests Action Status](https://camo.githubusercontent.com/15277c93d79ce9e23d2b66d6fd6e53c15a7a331c3d1a4ab404bbd2aebab0f3ab/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f6d61747469746a6161622f6c61726176656c2d706c61757369626c652d70726f78792f72756e2d74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://github.com/mattitjaab/laravel-plausible-proxy/actions?query=workflow%3Arun-tests+branch%3Amain)[![GitHub Code Style Action Status](https://camo.githubusercontent.com/5df4da9022beb114a2a59c2e731277be3497afee3a233e1a64d8d21aae2b79fd/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f6d61747469746a6161622f6c61726176656c2d706c61757369626c652d70726f78792f6669782d7068702d636f64652d7374796c652d6973737565732e796d6c3f6272616e63683d6d61696e266c6162656c3d636f64652532307374796c65267374796c653d666c61742d737175617265)](https://github.com/mattitjaab/laravel-plausible-proxy/actions?query=workflow%3A%22Fix+PHP+code+style+issues%22+branch%3Amain)[![Total Downloads](https://camo.githubusercontent.com/b0c95f58d9bc9d2d9af765cec0999db1fb694d91d0e75446d80be27e5ca8e185/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6d61747469746a6161622f6c61726176656c2d706c61757369626c652d70726f78792e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/mattitjaab/laravel-plausible-proxy)

A Laravel package for proxying Plausible Analytics, improving performance.

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

[](#requirements)

- Laravel 12
- PHP 8.3, 8.4

🚀 Installation
--------------

[](#-installation)

1. Install the package via Composer:

    ```
    composer require mattitjaab/laravel-plausible-proxy
    ```
2. Publish the configuration file:

    ```
    php artisan vendor:publish --tag=plausible-proxy-config
    ```
3. Add the following environment variables to your `.env` file:

    ```
    PLAUSIBLE_DOMAIN=https://plausible.io
    ```

⚙️ Configuration
----------------

[](#️-configuration)

The `config/plausible-proxy.php` file allows you to customize the plausible domain:

```
return [
    'domain' => env('PLAUSIBLE_DOMAIN', 'https://plausible.io'),
];
```

🔥 Usage
-------

[](#-usage)

### **1. Proxying the JavaScript file**

[](#1-proxying-the-javascript-file)

This package proxies Plausible's `script.js` while caching it to improve performance and reduce external requests.

After installation, you can include the script like this:

```

```

The route `/js/script.js` is automatically handled and caches the script for **6 hours**.

### **2. Sending Events to Plausible**

[](#2-sending-events-to-plausible)

Instead of sending events directly to plausible.io, the script is loaded from /js/script.js and proxies the request to Plausible via /api/event, helping to prevent blocking by ad blockers.

✅ Features
----------

[](#-features)

- 🚀 **Fast &amp; Optimized**: Caches the Plausible script to reduce external calls.
- ✅ No issues with ad blockers: Proxies the request via a local API endpoint.
- 🛠 **Fully Configurable**: Easily set your own Plausible instance via `.env`.

🛠 Testing
---------

[](#-testing)

You can run tests with:

```
composer test
```

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

Security Vulnerabilities
------------------------

[](#security-vulnerabilities)

Please review [our security policy](../../security/policy) on how to report security vulnerabilities.

Credits
-------

[](#credits)

- [Mathias Palmqvist](https://github.com/mathiaspalmqvist)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

41

—

FairBetter than 89% of packages

Maintenance75

Regular maintenance activity

Popularity11

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 81.8% 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 ~29 days

Recently: every ~36 days

Total

6

Last Release

321d ago

PHP version history (2 changes)v1.0PHP ^8.4

v1.2PHP ^8.3

### Community

Maintainers

![](https://www.gravatar.com/avatar/2f056a6d34a58ca4e884445093eb513ee4ae7977ecdd937c099a3ea8399cac0d?d=identicon)[Mattitja](/maintainers/Mattitja)

---

Top Contributors

[![mathiaspalmqvist](https://avatars.githubusercontent.com/u/51116221?v=4)](https://github.com/mathiaspalmqvist "mathiaspalmqvist (36 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (4 commits)")[![github-actions[bot]](https://avatars.githubusercontent.com/in/15368?v=4)](https://github.com/github-actions[bot] "github-actions[bot] (4 commits)")

---

Tags

laravelplausibleMattitja ABlaravel-plausible-proxyMattitjaAB

###  Code Quality

TestsPest

Static AnalysisPHPStan

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/mattitjaab-laravel-plausible-proxy/health.svg)

```
[![Health](https://phpackages.com/badges/mattitjaab-laravel-plausible-proxy/health.svg)](https://phpackages.com/packages/mattitjaab-laravel-plausible-proxy)
```

###  Alternatives

[spatie/laravel-data

Create unified resources and data transfer objects

1.7k28.9M627](/packages/spatie-laravel-data)[spatie/laravel-livewire-wizard

Build wizards using Livewire

4061.0M4](/packages/spatie-laravel-livewire-wizard)[hirethunk/verbs

An event sourcing package that feels nice.

513162.9k6](/packages/hirethunk-verbs)[worksome/exchange

Check Exchange Rates for any currency in Laravel.

123544.7k](/packages/worksome-exchange)[ralphjsmit/livewire-urls

Get the previous and current url in Livewire.

82270.3k4](/packages/ralphjsmit-livewire-urls)[hydrat/filament-table-layout-toggle

Filament plugin adding a toggle button to tables, allowing user to switch between Grid and Table layouts.

6292.3k1](/packages/hydrat-filament-table-layout-toggle)

PHPackages © 2026

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