PHPackages                             symfgenus/flagception-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. symfgenus/flagception-bundle

ActiveSymfony-bundle

symfgenus/flagception-bundle
============================

Feature toggle bundle on steroids.

24.8k

Since Nov 30Pushed 2y agoCompare

[ Source](https://github.com/hanishsingla/flagception-bundle)[ Packagist](https://packagist.org/packages/symfgenus/flagception-bundle)[ RSS](/packages/symfgenus-flagception-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Flagception
===========

[](#flagception)

**Feature toggle bundle on steroids!** Flagception is a simple and powerful feature toggle system for php. This bundle integrates the [Flagception PHP Library](https://packagist.org/packages/flagception/flagception) for symfony 2.7 to 6.\* (and php 5.6 to php 8.\*).

[![Latest Stable Version](https://camo.githubusercontent.com/7cd614857fcfe859341af8df937ce03148f65cf70eef8e5364111e87e251a14d/68747470733a2f2f706f7365722e707567782e6f72672f666c616763657074696f6e2f666c616763657074696f6e2d62756e646c652f762f737461626c65)](https://packagist.org/packages/flagception/flagception-bundle)[![Coverage Status](https://raw.githubusercontent.com/playox/flagception-bundle/image-data/coverage.svg)](https://raw.githubusercontent.com/playox/flagception-bundle/image-data/coverage.svg)[![Build Status](https://github.com/playox/flagception-bundle/actions/workflows/php.yml/badge.svg)](https://github.com/playox/flagception-bundle/actions)[![Total Downloads](https://camo.githubusercontent.com/42f65ca8a9e7a8c61bf94b3e4403cabb373b79f2591a92b4be27b5ac9d812521/68747470733a2f2f706f7365722e707567782e6f72672f666c616763657074696f6e2f666c616763657074696f6e2d62756e646c652f646f776e6c6f616473)](https://packagist.org/packages/flagception/flagception-bundle)[![License](https://camo.githubusercontent.com/e6e9d2496b6b1dc9c582f34191558736b86c6f5b5f5cfdbf5cfae3c529b5d679/68747470733a2f2f706f7365722e707567782e6f72672f666c616763657074696f6e2f666c616763657074696f6e2d62756e646c652f6c6963656e7365)](https://packagist.org/packages/flagception/flagception-bundle)

Bundle Version (Tag)Support SymfonyBranch&lt;=32.7 - 4.43.x&gt;=44.4 - currentmaster```
$ composer require flagception/flagception-bundle
```

Documentation
-------------

[](#documentation)

- [Installation](docs/install.md)
- [Upgrade from 2.x](UPGRADE-3.0.md)
- [Upgrade from 3.x](UPGRADE-4.0.md)
- [Usage](docs/usage.md)
- [Twig flags](docs/twig.md)
- [Route flags](docs/route.md)
- [Annotation flags](docs/annotation.md)
- [Constraints](docs/constraint.md)
- [Environment variables](docs/environment.md)
- [Cookies](docs/cookie.md)
- [Database](docs/database.md)
- [Activators](docs/activator.md)
- [Profiler](docs/profiler.md)

Quick example
-------------

[](#quick-example)

Set some feature in your config (or use your own [activator](docs/activator.md) for fetching features from wherever you want) ...

```
flagception:

    # Your Features (optional you left it empty)
    features:

        # Feature name as key
        feature_123:
            # Default flag if inactive or active (default: false)
            default: true

        # Feature state from an environment variable
        feature_abc:
            env: FEATURE_ENV_ABC

        # Feature with constraint (active if user id is 12 OR it is between 8 am and 6 pm)
        feature_def:
            constraint: 'user_id == 12 or (date("H") > 8 and date("H") < 18)'

        # All togther (chain)
        feature_def:
            default: false
            env: FEATURE_ENV_ABC
            constraint: 'user_id == 12 or (date("H") > 8 and date("H") < 18)'
```

... and use it in controller, services or twig:

```
{% if feature('feature_123') %}
    {# Execute if feature is active ... #}
{% endif %}
```

See [usage documentation](docs/usage.md) for detailed examples.

Profiler
--------

[](#profiler)

This bundle ships a profiler tab, where you can see how often a feature was requested, which results it returns (active or inactive) and the given context.

[![Image of Profiler](docs/images/profiler.png)](docs/images/profiler.png)

Credits
-------

[](#credits)

Profiler icon from

###  Health Score

19

—

LowBetter than 10% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity20

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity19

Early-stage or recently created project

 Bus Factor1

Top contributor holds 66.4% 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/a90cdbc9d7786cf264707be1608978e93006fccb8ed6ff06ceec1ea5d2680bf7?d=identicon)[hanishsingla](/maintainers/hanishsingla)

---

Top Contributors

[![migo315](https://avatars.githubusercontent.com/u/13180135?v=4)](https://github.com/migo315 "migo315 (93 commits)")[![teiling88](https://avatars.githubusercontent.com/u/4624237?v=4)](https://github.com/teiling88 "teiling88 (26 commits)")[![Haehnchen](https://avatars.githubusercontent.com/u/1011712?v=4)](https://github.com/Haehnchen "Haehnchen (5 commits)")[![ajgarlag](https://avatars.githubusercontent.com/u/388184?v=4)](https://github.com/ajgarlag "ajgarlag (4 commits)")[![mKnoop](https://avatars.githubusercontent.com/u/6775586?v=4)](https://github.com/mKnoop "mKnoop (3 commits)")[![RedactedProfile](https://avatars.githubusercontent.com/u/1039911?v=4)](https://github.com/RedactedProfile "RedactedProfile (2 commits)")[![Chris8934](https://avatars.githubusercontent.com/u/44963939?v=4)](https://github.com/Chris8934 "Chris8934 (2 commits)")[![hanish-singla](https://avatars.githubusercontent.com/u/6129169?v=4)](https://github.com/hanish-singla "hanish-singla (1 commits)")[![amacrobert](https://avatars.githubusercontent.com/u/1427361?v=4)](https://github.com/amacrobert "amacrobert (1 commits)")[![chq81](https://avatars.githubusercontent.com/u/1406816?v=4)](https://github.com/chq81 "chq81 (1 commits)")[![0x346e3730](https://avatars.githubusercontent.com/u/28731165?v=4)](https://github.com/0x346e3730 "0x346e3730 (1 commits)")[![morawskim](https://avatars.githubusercontent.com/u/1105278?v=4)](https://github.com/morawskim "morawskim (1 commits)")

### Embed Badge

![Health badge](/badges/symfgenus-flagception-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/symfgenus-flagception-bundle/health.svg)](https://phpackages.com/packages/symfgenus-flagception-bundle)
```

PHPackages © 2026

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