Custom metrics

Overview

This topic explains how to create Custom metrics in LaunchDarkly. Custom metrics require that you first instrument custom events in your application code using the LaunchDarkly SDK track() method.

When you create a custom metric in the LaunchDarkly user interface, you first select the event you have instrumented, and then LaunchDarkly displays data previews for the most recent events that it recorded. You can also filter the events you want to include a custom metric, based on context attributes or event properties.

Types of custom metrics

There are three types of custom metric you can create:

  • Custom conversion count metrics track how many times an event occurs. You can use this metric to measure activities such as how many times a customer submits a form or how many errors occur during a checkout process.
  • Custom conversion binary metrics track how many contexts trigger an event. For example, this metric can measure how many customers submit a form, or how many customers encounter a specific error.
  • Custom numeric metrics track changes to the amount of something, such as dollars spent or the time it takes to complete a process. For example, this metric can measure page load times or the time it takes a server to respond to a request.

SDK compatibility

You can instrument custom metric events and create custom metrics using any LaunchDarkly SDK. Read Sending custom events to learn more.