Impact metrics connect application data, such as request counts, error rates, or memory usage, to your feature flags and release plans.
You can use impact metrics in two areas:
By combining impact metrics with release templates, you can automate milestone progression and react automatically when metrics cross defined thresholds. For example:

For more use cases and how impact metrics fit into the broader release workflow, see Release management overview.
Unleash supports two metric sources: internal and external. Both support the same metric types and can be used in charts and safeguards.
Internal metrics are defined and recorded in your application using an Unleash SDK. The SDK sends metrics to Unleash, where they are stored and queried. See Record internal metrics for setup instructions.
External metrics are queried at read time from your existing Prometheus or VictoriaMetrics instance. The data stays in your system. Unleash does not ingest or store it. See Connect external metrics for setup instructions.
Internal and external metrics are completely separate in Unleash. Each chart or safeguard is configured against a specific source, and the metric selector labels entries by their source. A metric with the same name can exist in both sources without conflict.
If the external instance is unreachable or returns errors, only charts and safeguards configured against the external source are affected. Internal metrics continue to work normally.
Impact metrics support three data types:
Internal metrics are currently supported in a select number of SDKs. To request support for additional SDKs, contact beta@getunleash.io.
To use internal metrics, define a metric in the SDK and then record values for it. The SDK automatically attaches the following context labels: appName, environment, and origin (for example, origin=sdk or origin=Edge). These labels are available as filters when you create charts.
For language-specific examples, refer to your SDK documentation.
Internal metrics are batched and sent on the same interval as regular SDK metrics. They are ingested through the regular metrics endpoint.
Unleash Edge forwards internal metrics received from SDKs to the Unleash API. The origin label appears as origin=Edge. Daisy-chaining Edge instances is not supported.
If an Edge instance accumulates a large batch of metrics due to a temporary network disconnect, it sends them as a single bulk request upon reconnection. This appears as a spike in your counter graphs rather than a smooth distribution over time. This is expected behavior.
If you already collect metrics in Prometheus or VictoriaMetrics, you can connect your instance to Unleash and use those metrics in charts and safeguards without re-instrumenting your application through the SDK.
External metrics are not stored in Unleash. Unleash queries your instance at read time when a chart is viewed or a safeguard is evaluated.
You can configure external metrics from the Admin UI on both Unleash Hosted and self-hosted instances.
Unleash appends the standard Prometheus HTTP API paths (/api/v1/...) to this base URL, so do not include /api/v1 yourself. A trailing slash is accepted and ignored. Examples:
https://prometheus.example.comhttps://victoria.example.com/select/<tenantId>/prometheusThe URL must be reachable from the Unleash server over the network. Each request has a 20-second timeout.
HTTP Basic Auth is supported by embedding credentials in the URL (for example, https://user:password@prometheus.example.com). Credentials in URLs can appear in server logs. Use a secrets manager or other secure mechanism if you provision the URL through configuration rather than the Admin UI.
If you prefer to manage configuration outside the Admin UI on a self-hosted instance, set the EXTERNAL_PROMETHEUS_IMPACT_METRICS_API environment variable on your Unleash server to the base URL of your Prometheus or VictoriaMetrics instance. Unleash must be restarted for changes to take effect.
Prometheus and VictoriaMetrics typically expose many infrastructure metrics that are not relevant as impact metrics. Unleash filters these out of the metric selector.
Unleash excludes the reserved names up, ALERTS, and ALERTS_FOR_STATE, and any metric whose name starts with a well-known infrastructure prefix: go_, process_, prometheus_, promhttp_, scrape_, vm_, vmagent_, vminsert_, vmselect_, container_, kube_, or similar tooling prefixes. If one of your own metrics collides with an excluded prefix, rename it to make it visible.
You can visualize both internal and external metrics in the Unleash Admin UI.
appName, environment, or origin. For external metrics, filter by any custom labels exposed by your Prometheus or VictoriaMetrics instance.
There is a 1-2 minute delay between data generation and visualization for internal metrics due to the ingestion cycle. External metrics reflect whatever data is currently available in your Prometheus or VictoriaMetrics instance.
Impact metrics integrate with release templates to automate the rollout process. Instead of manually advancing milestones, Unleash can progress automatically when time conditions are met.
To configure automatic progression:
When the time conditions are satisfied, Unleash advances the release to the next milestone.
Safeguards automatically react when an impact metric crosses a threshold. You can configure safeguards against both internal and external metrics.
Safeguards are attached to a feature flag’s environment, so you can react differently in development, staging, and production using the same metric.
When you add a safeguard, you choose an action that runs if the metric crosses the threshold:
Before you start, verify that your metric is available by selecting Add safeguard and checking the dropdown. For internal metrics, it may take up to 60 seconds for a new metric to appear because the SDK sends metrics on a default 60-second interval.
To add a safeguard to an environment:
analyze_feature_errorWhen the metric crosses the threshold, Unleash runs the configured action for that environment.
Safeguards work the same way for both internal and external metrics, with the following differences for external metrics:
environment label to the metric whose value matches the environment name (for example, environment="production"). The safeguard then only evaluates time series with that label. If the environment label is missing, the metric is available in every environment with no per-environment filtering.Connecting an external instance adds read load to your Prometheus or VictoriaMetrics, similar to Grafana or other query-time tools. Plan capacity accordingly as the number of charts and active safeguards grows.
Unleash issues the following Prometheus HTTP API requests:
Metadata requests run when you open the chart or safeguard configuration UI. Range queries run when charts are viewed and each time a safeguard is evaluated.