Read time: 4 minutes
Last edited: Feb 27, 2023
Experimentation is available to customers on a Pro or Enterprise plan. To learn more, read about our pricing. To add Experimentation to your plan, contact Sales.
This topic explains the concepts and value of LaunchDarkly's Experimentation feature. Experiments let you measure the effect of flags on end users by tracking metrics your team cares about.
Experimentation lets you validate the impact of features you roll out to your app or infrastructure. You can measure things like page views, clicks, load time, infrastructure costs, and more.
By connecting metrics you create to flags in your LaunchDarkly environment, you can measure the changes in your customer's behavior based on what flags they evaluate. This helps you make more informed decisions, so the features your development team ships align with your business objectives.
To learn about Experimentation use cases, read Example experiments.
To use Experimentation, you must have the following prerequisites:
- You must be using the listed version number or higher for the following SDKs.
Click to expand a table listing required client-side SDK versions
|React Web||All versions|
Click to expand a table listing required server-side SDK versions
- If you use the LaunchDarkly Relay Proxy, it must be at least version 6.3.0.
- You must have audience allocation enabled on your account. If you do not have allocation enabled or you are unsure, contact Support.
When you request that we enable audience allocation for your account, we will ask you to confirm that you are using SDK and Relay Proxy versions that support this feature. If your SDK and Relay Proxy versions are outdated, contexts will receive different flag variations across various SDKs, rendering your experimentation results invalid.
If you are currently running any experiments, enabling audience allocation does not affect those experiments. Each of your experiments will continue to record results for the same audience until you pause the experiment. After you enable audience allocation, all new or paused experiments will require an audience allocation before you can begin recording.
We designed Experimentation to be accessible to a variety of roles within your organization. For example, product managers can use experiments to measure the value of the features they ship, designers can test multiple variations of UI and UX components, and DevOps engineers can test the efficacy and performance of their infrastructure changes.
If an experiment tells you a feature has positive impact, you can roll that feature out to your entire user base to maximize its value. Alternatively, if you don't like the results you're getting from a feature, you can toggle the flag off and minimize its impact on your user base.
Some of the things you can do with Experimentation include:
- A/B/n testing, also called multivariate testing
- Start and stop experiments at any time so you have immediate control over which variations your customers encounter
- Review credible intervals in experiment results so you can decide which variation you can trust to have the most impact
- Target specific groups of contexts or segments to experiments, refining your testing audience
- Measure the impact of changes to your product at all layers of your technology stack
- Roll out product changes in multiple stages, leveraging both Experimentation and workflows
To lean more, read Designing experiments.
Analyzing experiment results
Experiment data is collected on an experiment's Results tab, which displays experiment data in near-real time. To learn more, read Analyzing experiments.
As your experiment collects data, LaunchDarkly calculates the variation that is most likely to be the best choice out of all the variations you're testing. After you decide which flag variation has the impact you want, you can gradually roll that variation out to 100% of your customers with LaunchDarkly's percentage rollouts feature. To learn more about percentage rollouts, read Percentage rollouts.
You can export experiment data to an external destination using Data Export. To learn more, read Data Export.
Experimentation best practices
As you use Experimentation, consider these best practices:
- Use feature flags on every new feature you develop. This is a best practice, but it especially helps when you're running experiments in LaunchDarkly. By flagging every feature, you can quickly turn any aspect of your product into an experiment.
- Run experiments on as many feature flags as possible. This creates a culture of experimentation that helps you detect unexpected problems and refine and pressure-test metrics.
- Consider experiments from day one. Create hypotheses in the planning stage of feature development, so you and your team are ready to run experiments as soon as your feature launches.
- Define what you're measuring. Align with your team on which tangible metrics you're optimizing for, and what results constitute success.
- Plan your experiments in relation to each other. If you're running multiple experiments simultaneously, make sure they don't collect similar or conflicting data.
- Associate end users who interact with your app before and after logging in. If someone accesses your experiment from both a logged out and logged in state, each state will generate its own context key. You can associate multiple related contexts together using multi-contexts. To learn more, read Associating anonymous contexts with logged-in end users.
You can use experiments to measure a variety of different outcomes. Some example experiments include:
- Testing the efficacy of different search implementations, such as Elasticsearch versus SOLR versus Algolia
- Tracking how features you ship are increasing or decreasing page load time
- Calculating conversion rates by monitoring how frequently end users click on various page elements
- Testing the impact of new artificial intelligence and machine learning (AI/ML) models on end-user behavior and product performance.
Experiments are billed monthly based on the number of unique context keys in each experiment. To learn more about context keys, read Built-in attributes.
Your billing month begins on the same day of the month your contract began with LaunchDarkly. For example, if your contract with LaunchDarkly began on January 15th, your Experimentation billing month resets the 15th of every month. To estimate your Experimentation billing costs, multiply the number of experiments you run each month by the number of unique context keys in your experiment audiences. If an experiment has multiple iterations, it is still counted as one experiment. If the same context key appears in two different experiments, they key is counted twice for billing purposes.
Customers on older contracts may be billed by Experimentation event count, rather than unique context keys. To learn more, read Experimentation events. If you are unsure about how you are being billed for Experimentation, contact Sales or your LaunchDarkly Account Executive.