# Set Up Feature Flags | Sentry for Laravel

## [Requirements](https://docs.sentry.io/platforms/php/guides/laravel/feature-flags.md#requirements)

* [Laravel SDK](https://docs.sentry.io/platforms/php/guides/laravel.md) version `4.19.0` or above.

## [Enable Evaluation Tracking](https://docs.sentry.io/platforms/php/guides/laravel/feature-flags.md#enable-evaluation-tracking)

### [Laravel Pennant](https://docs.sentry.io/platforms/php/guides/laravel/feature-flags.md#laravel-pennant)

If you use Laravel Pennant together with the Sentry Laravel SDK, Sentry automatically tracks your feature flag evaluations for you.

When using [rich values](https://laravel.com/docs/pennant#rich-feature-values), it is important to know that a feature is considered "active" when it has any value other than false.

Each event can record up to 100 feature flag evaluations; if more are sent, only the most recent 100 are kept.

```php
use Laravel\Pennant\Feature;

if (Feature::active('test-flag')) {
    // do some work
}

\Sentry\captureException(new \RuntimeException('Something went wrong!'));
```

Go to your Sentry project and confirm that your error event has recorded the feature flag "test-flag" and its evaluated value.
