Read time: 1 minute
Last edited: Jun 15, 2022
This topic explains how to create a metric to use within an experiment in LaunchDarkly.
Metrics are the measure against which you evaluate flag events. You can use metrics to track all kinds of things, from how often users access a URL to how long that URL takes to load a page. Create metrics that align with your business goals and connect them to your team's flags to track the impact of different flag variations over time.
You can use two different types of metrics to track experiment results in LaunchDarkly. They are:
- Conversion metrics register events when a user takes an action based on a feature flag they encounter.
- Numeric metrics measure numeric values against a baseline you set.
These metrics can track different kinds of user events, such as viewing a page or clicking on a link. There are four different types of metrics:
The following table explains the kinds of events you can track with a metric:
|Event kind||Metric type||Description||SDK compatibility|
|Custom||Conversion||Tracks events for any arbitrary event. For example, whether a user search called a service or not.||All|
|Custom||Numeric||Tracks increases or decreases in numeric value against a baseline you set. For example, how many items are in a user's cart when they check out of your online store.||All|
To learn more about Experimentation events, read Experimentation events.
After you create a metric, you can use it in an experiment. To learn how, read Building experiments.
You should delete a metric only when you are sure you will no longer use it in any experiments.
To delete a metric:
- Navigate to the Experiments dashboard.
- Click the Metrics tab.
- Click the title of the metric you want to delete. The "Edit metric" panel appears.
- Click Delete this metric.
This metric is now deleted permanently across all environments in the project.