PHPackages                             ekyna/cookie-consent-bundle - 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. ekyna/cookie-consent-bundle

ActiveSymfony-bundle[Utility &amp; Helpers](/categories/utility)

ekyna/cookie-consent-bundle
===========================

Cookie consent (GDPR)

0.9.x-dev(3y ago)22.0kMITPHPPHP &gt;=8.1

Since Nov 25Pushed 3y ago1 watchersCompare

[ Source](https://github.com/ekyna/CookieConsentBundle)[ Packagist](https://packagist.org/packages/ekyna/cookie-consent-bundle)[ Docs](https://github.com/ekyna/CookieConsentBundle)[ RSS](/packages/ekyna-cookie-consent-bundle/feed)WikiDiscussions 0.7 Synced 1mo ago

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

CookieConsentBundle
===================

[](#cookieconsentbundle)

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

[](#installation)

```
composer require ekyna/cookie-consent-bundle

```

#### Register bundle and routes

[](#register-bundle-and-routes)

```
// app/AppKernel.php
public function registerBundles()
{
    $bundles = [
        // ...
        new Ekyna\Bundle\CookieConsentBundle\EkynaCookieConsentBundle(),
    ];
    // ...
}
```

```
# app/config/routing.yml
ekyna_cookie_consent:
    resource: "@EkynaCookieConsentBundle/Resources/config/routing.yaml"
```

#### Use twig functions

[](#use-twig-functions)

```
{# base.html.twig #}

  {# ... #}

  {% block javascripts %}
    {# Renders the cookie consent widget (if not yet consented) #}
    {{ ekyna_cookie_consent_render() }}

    {# Check if cookie category has user consent ('analytic', 'marketing' or 'social_network') #}
    {% if ekyna_cookie_consent_category_allowed('analytic') %}

    {% endif %}
  {% endblock javascripts %}

```

*ekyna\_cookie\_consent\_render()* options with their default values:

```
{{ ekyna_cookie_consent_render({
    render_if_saved: false, // Whether to render even if consent has been saved.
    expanded: false,        // Whether to show settings
    dialog: true            // Whether to render as a dialog/popup
}) }}
```

#### Configuration

[](#configuration)

Available configuration with default values.

```
# app/config/config.yml
ekyna_cookie_consent:
    name: Cookie_Content   # The consent cookie name
    read_more_route: ~     # Route name to your privacy policy page
    position: centered     # Widget positioning ('centered' or 'bottom-right')
    categories:            # Cookies categories the user has to consent
        - analytic
        - marketing
        - social_network
    persist: true          # Whether to persist user consent
```

TODO
----

[](#todo)

- Encrypt cookie consent entity's **IP** property.

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity21

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity49

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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 ~293 days

Total

3

Last Release

1406d ago

PHP version history (3 changes)0.7.x-devPHP &gt;=7.2

0.8.x-devPHP &gt;=7.4

0.9.x-devPHP &gt;=8.1

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3483641?v=4)[Etienne Dauvergne](/maintainers/ekyna)[@ekyna](https://github.com/ekyna)

---

Top Contributors

[![ekyna](https://avatars.githubusercontent.com/u/3483641?v=4)](https://github.com/ekyna "ekyna (10 commits)")

---

Tags

symfonybundlecommerce

### Embed Badge

![Health badge](/badges/ekyna-cookie-consent-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/ekyna-cookie-consent-bundle/health.svg)](https://phpackages.com/packages/ekyna-cookie-consent-bundle)
```

###  Alternatives

[lexik/translation-bundle

This bundle allows to import translation files content into the database and provide a GUI to edit translations.

4362.7M19](/packages/lexik-translation-bundle)[pentatrion/vite-bundle

Vite integration for your Symfony app

2725.3M13](/packages/pentatrion-vite-bundle)[artgris/filemanager-bundle

FileManager is a simple Multilingual File Manager Bundle for Symfony

182420.8k9](/packages/artgris-filemanager-bundle)[netgen/layouts-core

Netgen Layouts enables you to build and manage complex web pages in a simpler way and with less coding. This is the core of Netgen Layouts, its heart and soul.

3689.4k10](/packages/netgen-layouts-core)[jbtronics/settings-bundle

A symfony bundle to easily create typesafe, user-configurable settings for symfony applications

9546.7k2](/packages/jbtronics-settings-bundle)[pixelopen/cloudflare-turnstile-bundle

A simple package to help integrate Cloudflare Turnstile on Symfony.

31205.8k3](/packages/pixelopen-cloudflare-turnstile-bundle)

PHPackages © 2026

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