✅ Laravel Cookie Consent – Plug & play GDPR/DSGVO modal
Martin Schenk

Martin Schenk @falk_maria_zeitsprung

About: Fullstack web app developer. German, living in beautiful Madrid, Spain. Always learning.

Location:
Madrid, Spain
Joined:
Nov 13, 2019

✅ Laravel Cookie Consent – Plug & play GDPR/DSGVO modal

Publish Date: May 30
0 1

Image description

Hey folks! 👋
I just released a lightweight, developer-friendly cookie consent plugin for Laravel 11+ projects. It’s focused on real GDPR/DSGVO compliance – with a configurable modal, full Alpine.js support, language preferences, and real-time cookie blocking.

🔹 Easy to install
🔹 No frontend lock-in (customizable view & JS logic)
🔹 Works with Tailwind or plain CSS
🔹 Built for modern Laravel stacks

Check it out here:
👉 https://github.com/martinschenk/laravel-cookie-consent

Feedback, stars ⭐️ and contributions are very welcome! 🙏

Comments 1 total

  • Martin Schenk
    Martin SchenkMay 30, 2025

    For developers building apps in (or for) the EU:
    🛑 You legally must not set any non-essential cookies before explicit user consent.
    This includes analytics, ads (like Google Ads), YouTube embeds, etc.

    Also:
    Even cookies used by your application (like for language preferences or UI settings) must not be set unless consent is already given – unless they’re strictly necessary.

    💡 That’s exactly why I built this Laravel plugin.
    It handles all of this out of the box:
    • No cookies are set too early
    • Full modal-based consent flow
    • Users can reopen the modal anytime to update preferences
    • Revoking consent automatically blocks & removes cookies again (like Google Ads)
    • Works great with Alpine.js & Tailwind – or plain setups
    • Super easy to install & customize

    Check it out:
    👉 github.com/martinschenk/laravel-co...

    Hope it saves you a ton of time — and legal headaches.

Add comment