> For the complete documentation index, see [llms.txt](https://docs.datarhei.com/core/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.datarhei.com/core/configuration/metrics.md).

# Metrics

Settings for collecting metrics of the core and FFmpeg processes.

## Configuration

{% tabs %}
{% tab title="JSON" %}

```
{
   "metrics": {
      "enable": false,
      "enable_prometheus": false,
      "range_sec": 300,
      "interval_sec": 2
   }
}
```

{% endtab %}

{% tab title="ENV" %}

```
CORE_METRICS_ENABLE=false
CORE_METRICS_ENABLE_PROMETHEUS=false
CORE_METRICS_RANGE_SECONDS=300
CORE_METRICS_INTERVAL_SECONDS=2
```

{% endtab %}
{% endtabs %}

{% hint style="warning" %}
Caution with many processes and low values! It will increases CPU and RAM usage.
{% endhint %}

### enable (bool)

Enable collecting metrics data of the datarhei Core itself and the FFmpeg processes. The metrics can be queried via the [metrics API endpoint](/core/api/metrics.md).

By default collecting the metrics is disabled.

### enable\_prometheus (bool)

Enable prometheus endpoint at `/metrics`. This requires that collecting metrics is enabled.

By default this is disabled.

### range\_sec (integer)

Define for how many seconds historic metrics data should be kept.

By default this value is set to `300`.

### interval\_sec (integer)

Define in which interval (in seconds) the metrics should be collected.

By default this value is set to `2`.
