dev-tools 5 min read

GrowthBook - Open-Source Feature Flags and A/B Testing

Self-host GrowthBook for feature flagging, A/B experiments, and product analytics with 24 SDKs, warehouse-native data sources, and a built-in stats engine.

By
Share: X in
GrowthBook feature flagging and experimentation dashboard

TL;DR

TL;DR: GrowthBook is an open-core platform for feature flags, A/B testing, and product analytics — deploy with Docker, connect to your data warehouse, and ship experiments with 24 SDKs.

Source and Accuracy Notes

⚠️ This section is MANDATORY. All links must be verified from actual source, not guessed.

What Is GrowthBook?

Feature flags and A/B testing are standard practice at high-growth companies, but building an in-house platform requires significant engineering investment. GrowthBook brings the experimentation infrastructure of top tech companies to any organization as an open-core, self-hostable platform.

The project describes itself as:

Open Source Feature Flags, Experimentation, and Product Analytics

It ships with:

  • Feature flags with advanced targeting, gradual rollouts, and experiments
  • 24 SDKs including React, Python, Kotlin, Swift, Go, Ruby, PHP, Java, and more
  • A statistics engine with CUPED, Sequential, Bayesian, Post-Strat, Bandits, and SRM checks
  • Warehouse Native — connects to BigQuery, Snowflake, Databricks, Redshift, Postgres, MySQL, ClickHouse, Athena, Mixpanel, Google Analytics, and more
  • Built-in product analytics for dashboards
  • Webhooks and a full REST API
  • An MCP server for creating features, starting experiments, and cleaning up stale flags programmatically

Setup Workflow

Self-hosting GrowthBook takes a single docker compose command:

git clone https://github.com/growthbook/growthbook.git
cd growthbook
docker compose up -d

Then visit http://localhost:3000. See the Self-Hosting Instructions for full details.

Option 2: GrowthBook Cloud

Create a free account at app.growthbook.io to get started without deploying anything.

Connect a Data Source

After setup, connect GrowthBook to your data warehouse:

  1. Navigate to Settings → Datasources
  2. Add your warehouse (BigQuery, Snowflake, Databricks, Postgres, MySQL, ClickHouse, etc.)
  3. Define your metrics using SQL-backed definitions
  4. Start creating experiments and feature flags

GrowthBook’s warehouse-native approach means experiment data stays in your own infrastructure — no data leaves your warehouse.

How Feature Flags Work

A feature flag in GrowthBook maps a feature key to a boolean or string value, with targeting rules that determine which users see which value:

// Example: targeting a percentage rollout
if (feature.enabled("new-checkout-flow", user)) {
  // show new checkout
} else {
  // show existing checkout
}

Targeting rules support:

  • Percentage rollouts (e.g., 10% of users)
  • User attribute matching (country, plan, user ID, custom attributes)
  • Environments (dev/staging/production)
  • Experiment overrides for QA

Experiment Statistics

GrowthBook ships with a mature statistics engine:

  • CUPED — reduces variance using pre-experiment data
  • Sequential testing — valid results before an experiment “reaches significance”
  • Bayesian — probability distributions over outcomes
  • Bandits — multi-armed bandit optimization for adaptive experiments
  • SRM checks — detects sample ratio mismatch from assignment bugs

The MCP Server

GrowthBook includes an MCP server that lets AI agents interact with the platform:

# Start the MCP server
npx @growthbook/sdk-mcp-server

From the documentation, the MCP server can:

  • Create and update feature flags
  • Start and stop experiments
  • List and clean up stale flags
  • Query experiment results

Security Notes

  • GrowthBook does not store experiment data — it queries your data warehouse directly
  • The self-hosted version gives you full control over your data and infrastructure
  • API keys for data sources are stored securely in the application settings
  • The MIT-licensed core contains the full feature set; the Enterprise License adds commercial-only features

FAQ

Q: How is GrowthBook different from LaunchDarkly or Statsig? A: GrowthBook is open source and self-hostable. LaunchDarkly and Statsig are SaaS-only. GrowthBook’s warehouse-native architecture also means your raw data never leaves your own infrastructure.

Q: Does it support multivariate testing (more than A vs. B)? A: Yes. GrowthBook supports multi-arm bandit experiments with more than two variants.

Q: What data warehouse does it connect to? A: BigQuery, Snowflake, Databricks, Redshift, Postgres, MySQL, ClickHouse, Athena, Mixpanel, Google Analytics, and heap — see the full datasource list.

Q: Is the open-source version fully functional? A: The MIT-licensed core includes all major features: feature flags, experiments, analytics, all SDKs, and the MCP server. A subset of advanced enterprise features are under a commercial license.

Q: Can non-technical team members use it? A: Yes. GrowthBook has a visual UI for creating experiments, setting targeting rules, and viewing results. Technical integration is only needed for the SDK side.

Conclusion

GrowthBook closes the gap between the experimentation platforms used by tech giants and what smaller teams can afford to build or subscribe to. The self-hosted Docker deployment makes it practical for any team, and the warehouse-native design keeps data ownership clear. With 24 SDKs and a mature statistics engine, it is a credible alternative to expensive SaaS experimentation tools.

Get started with git clone and docker compose up at github.com/growthbook/growthbook, or try the cloud version at app.growthbook.io.