PromQL reference
The Prometheus Query Language (PromQL) is a functional query language to select and aggregate metrics.
This functionality is in technical preview and might be changed or removed in a future release. Elastic will work to fix any issues, but features in technical preview are not subject to the support SLA of official GA features.
Elasticsearch supports PromQL queries for metrics in time series data streams (TSDS). PromQL support is not limited to metrics ingested through Prometheus remote write. All TSDS are supported, including metrics ingested through OpenTelemetry Protocol (OTLP), and the bulk API.
Elasticsearch supports PromQL in two ways: through a Prometheus-compatible HTTP API (for Prometheus-compatible clients) and as a PROMQL source command inside piped ES|QL queries that allow post-processing through regular ES|QL.
When you use the Prometheus-compatible HTTP API or embed PromQL in an ES|QL query through the PROMQL source command, Elasticsearch parses PromQL into ES|QL logical plans and evaluates those plans against TSDS metrics.
Elasticsearch uses the same ES|QL compute engine for PromQL as for the TS source command.
- HTTP API: Prometheus-compatible
/_prometheus/endpoints for queries and discovery. - Limitations: How behavior differs from Prometheus, including unsupported PromQL constructs, HTTP behavior, instant-query nuances, staleness semantics, exemplars, and related topics.