Search by

jeffersongoncalves / filament-cloudflare-web-analytics

jeffersongoncalves

Filament plugin for Cloudflare Web Analytics: injects the tracking script into your panels and adds a settings page, powered by Spatie Laravel Settings.

Package info

github.com/jeffersongoncalves/filament-cloudflare-web-analytics

pkg:composer/jeffersongoncalves/filament-cloudflare-web-analytics

Statistics

Installs: 5

Dependents: 0

Suggesters: 0

Stars: 1

Open Issues: 0

3.1.0 2026-10-09 11:34 UTC

README

Filament Cloudflare Web Analytics

Filament Cloudflare Web Analytics

Buy Me A Coffee

Latest Version on Packagist GitHub Code Style Action Status Total Downloads License

Filament plugin for Cloudflare Web Analytics — privacy-first, cookie-free analytics from Cloudflare — with a settings page powered by Spatie Laravel Settings. Manage Cloudflare Web Analytics from the Filament admin panel; the script is injected into the <head> of every panel page.

Built on top of jeffersongoncalves/laravel-cloudflare-web-analytics.

Compatibility

Branch Filament Package version
1.x 3.x ^1.0
2.x 4.x ^2.0
3.x 5.x ^3.0

Installation

composer require jeffersongoncalves/filament-cloudflare-web-analytics:"^3.0"

Publish the settings migrations and run them:

php artisan vendor:publish --tag=cloudflare-web-analytics-settings-migrations
php artisan migrate

Usage

use JeffersonGoncalves\Filament\CloudflareWebAnalytics\CloudflareWebAnalyticsPlugin;

public function panel(Panel $panel): Panel
{
    return $panel
        ->plugins([
            CloudflareWebAnalyticsPlugin::make(),
        ]);
}

The plugin registers a Cloudflare Web Analytics settings page and injects the script into the <head> of every panel page once the settings are complete.

Field Label
token Site token

Disable the Settings Page

CloudflareWebAnalyticsPlugin::make()
    ->settingsPage(false),

To render the script outside Filament, add @include('cloudflare-web-analytics::script') to your own layout.

Navigation group

Put the settings page in one of your panel's own navigation groups (a string or a closure):

CloudflareWebAnalyticsPlugin::make()
    ->navigationGroup(fn (): string => __('admin.navigation.settings')),

Requirements

  • PHP 8.2 or higher
  • Filament 5.x

Changelog

Please see CHANGELOG for more information on what has changed recently.

Contributing

Please see CONTRIBUTING for details.

Security Vulnerabilities

Please review our security policy on how to report security vulnerabilities.

Credits

License

The MIT License (MIT). Please see License File for more information.