GrowthBook Version 2.8

Prerequisite flags, code references, versioned metrics, and more

Graham McNicoll
GrowthBook
4 min readFeb 26, 2024

--

We’re excited to announce the release of GrowthBook 2.8, with many highly requested features, including Prerequisite Flags, Code References, and a new “No Access” role. Full details are below.

Prerequisite Flags

Prerequisite flags UI, showing this feature flag is dependent on another flag

With Prerequisites, you can group together related feature flags and describe complex relationships between them. For example, you can have a bunch of features that all reference a `release-2.8` parent flag as a prerequisite. The child features will only be enabled when the parent flag evaluates to `true`.

Prerequisites can also be defined at the individual rule or experiment level. For example, only include users in your experiment who are getting assigned `b` of a separate `pricing-page-version` feature flag.

Top-level Prerequisites are available to all Pro and Enterprise customers. Rule-level and Experiment-level Prerequisites are only available to Enterprise customers. Simple cases where the prerequisite is deterministic (e.g. always true or always false) work in all SDKs with no configuration required. Advanced cases (e.g. prerequisite’s value depends on an experiment) are currently only supported in the latest JavaScript and React SDK versions. Read more about this in our docs.

Feature Code References

Example showing feature references in the code

Back in GrowthBook 2.6, we added stale feature flag detection. Now with Code Refs, we’re making that more actionable by showing you exactly where a feature is being used in your application’s code base.

Setup is easy — Just add a new job to your application’s CI pipeline that runs whenever code is pushed. This CI job fetches a list of feature flags from the GrowthBook REST API, scans your code base for references, and sends back the line numbers and surrounding code to GrowthBook so it can be displayed in the UI.

If you use GitHub Actions, we provide a pre-built action you can install. We don’t have official integrations for other CI platforms at this time, but we have published a low-level CLI script and Docker image you can use to integrate manually. Code References are available to all Pro and Enterprise customers.

Official (Version Controlled) Metrics

It’s not uncommon for large organizations to have hundreds or thousands of experimentation metrics. These are often a mix of “Official” metrics (widely used and vetted by the data team) and Ad-Hoc metrics (one-off, created by a product team, etc.). GrowthBook 2.8 introduces a brand new workflow that can make this distinction clearer and lead to more trustworthy experimentation.

In a nutshell, you can now store your Official Metric definitions as code in a version control system like GitHub and changes can be automatically synced to your GrowthBook account. These Official Metrics are marked with a special badge and cannot be edited from within the GrowthBook UI. Whenever you see the Official badge, you can be confident that the definitions have gone through your version control and review process.

Check out our tutorial for storing Official Metrics in GitHub.

“No Access” Role

In previous versions, the lowest role you could grant someone in your GrowthBook account was “readonly”. This meant that every user you invited to your organization could, at the very least, see every single feature flag, experiment, etc., in your account.

GrowthBook 2.8 introduces a new role called “No Access”. As the name suggests, this is even lower than “readonly” and essentially grants no permissions whatsoever. When combined with project-scoped roles, this becomes super powerful. For example, grant someone a global role of “No Access” and then override this with a more permissive role for specific projects. That user would not even be able to see the projects they don’t explicitly have access to and all of the associated feature flags, experiments, etc. would be hidden from them.

This new role is available to all Enterprise customers. You can read more about this in our docs.

Webhooks for SDK Connections

Every SDK Connection in GrowthBook gets a dedicated API endpoint that returns a JSON payload of all included feature flags and experiments. You can now attach Webhooks to an SDK Connection so you can be alerted any time this payload changes. For example, if you have a caching layer in front of GrowthBook, you can use a Webhook to invalidate your cache, resulting in faster feature releases to your users.

Other Improvements

  • New guide on integrating GrowthBook with WordPress sites — view it here
  • Metric lookback windows
  • Option to ignore zeros in percentile capping
  • JumpCloud SSO support
  • Plus, more than 50 documentation and bug fixes!

--

--

Graham McNicoll
GrowthBook

Co-founder of GrowthBook (growthbook.io) — open source feature flagging and experimentation. Previously CTO of an ed-tech startup and 3x founder.