<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>SLI examples for Grafana SLO on Grafana Labs</title><link>https://grafana.com/docs/plugins/grafana-slo-app/v1.65.0+c3f6e740273a3d27df7357f42c2234d42c03bb31/sli-examples/</link><description>Recent content in SLI examples for Grafana SLO on Grafana Labs</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="/docs/plugins/grafana-slo-app/v1.65.0+c3f6e740273a3d27df7357f42c2234d42c03bb31/sli-examples/index.xml" rel="self" type="application/rss+xml"/><item><title>SLI example for availability</title><link>https://grafana.com/docs/plugins/grafana-slo-app/v1.65.0+c3f6e740273a3d27df7357f42c2234d42c03bb31/sli-examples/availability/</link><pubDate>Sat, 04 Apr 2026 20:10:38 +0000</pubDate><guid>https://grafana.com/docs/plugins/grafana-slo-app/v1.65.0+c3f6e740273a3d27df7357f42c2234d42c03bb31/sli-examples/availability/</guid><content><![CDATA[&lt;h1 id=&#34;sli-example-for-availability&#34;&gt;SLI example for availability&lt;/h1&gt;
&lt;p&gt;This guide provides examples to show how to define &lt;strong&gt;availability SLIs&lt;/strong&gt; based on successful HTTP responses and probe results. The examples explain various methods to define SLIs using distinct Prometheus metric types.&lt;/p&gt;
&lt;p&gt;First, it&amp;rsquo;s important to understand what Grafana SLO expects from an SLI.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Grafana supports event-based SLIs, which measure the &lt;strong&gt;ratio of successful events to total events&lt;/strong&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;The &lt;strong&gt;SLI query result must return a ratio between 0 and 1&lt;/strong&gt;, where &lt;code&gt;1&lt;/code&gt; means &lt;code&gt;100%&lt;/code&gt; of events were successful.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Grafana expects SLIs to be expressed as a ratio-like query: &lt;code&gt;numerator / denominator&lt;/code&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Depending on the type of metric, you can calculate the ratio of successful events using counts or rates:&lt;/p&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;Success ratio = number of successful events (over a period)
                /
                total number of events (over a period)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;Success ratio = rate of successful events (over a period)
                /
                rate of total events (over a period)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Both formulas produce the ratio of successful events, a value between &lt;code&gt;0&lt;/code&gt; and &lt;code&gt;1&lt;/code&gt;.&lt;/p&gt;
&lt;figure
    class=&#34;figure-wrapper figure-wrapper__lightbox w-100p &#34;
    style=&#34;max-width: 1292px;&#34;
    itemprop=&#34;associatedMedia&#34;
    itemscope=&#34;&#34;
    itemtype=&#34;http://schema.org/ImageObject&#34;
  &gt;&lt;a
        class=&#34;lightbox-link&#34;
        href=&#34;/media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png&#34;
        itemprop=&#34;contentUrl&#34;
      &gt;&lt;div class=&#34;img-wrapper w-100p h-auto&#34;&gt;&lt;img
          class=&#34;lazyload &#34;
          data-src=&#34;/media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png&#34;data-srcset=&#34;/media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=320 320w, /media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=550 550w, /media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=750 750w, /media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=900 900w, /media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=1040 1040w, /media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=1240 1240w, /media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=1920 1920w&#34;data-sizes=&#34;auto&#34;alt=&#34;Screenshot of the graph result of an SLI ratio&#34;width=&#34;1292&#34;height=&#34;516&#34;/&gt;
        &lt;noscript&gt;
          &lt;img
            src=&#34;/media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png&#34;
            alt=&#34;Screenshot of the graph result of an SLI ratio&#34;width=&#34;1292&#34;height=&#34;516&#34;/&gt;
        &lt;/noscript&gt;&lt;/div&gt;&lt;/a&gt;&lt;/figure&gt;
&lt;p&gt;In the Grafana SLO wizard, you can create these SLIs using two methods:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Ratio query builder&lt;/strong&gt;: Enter a counter metric for success events and a counter metric for total events, and it auto-generates the final SLI query.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Advanced&lt;/strong&gt;: Enter the ratio SLI query directly.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&#34;http-availability-using-prometheus-counter&#34;&gt;HTTP availability (using Prometheus Counter)&lt;/h2&gt;
&lt;p&gt;HTTP availability is a common SLI for frontend and API services, defining availability as requests that do not return server errors (&lt;code&gt;5xx&lt;/code&gt; status codes).&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Number of successful events&lt;/strong&gt;: All non-5xx requests&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Total number of events&lt;/strong&gt;: All HTTP requests&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;This example uses &lt;code&gt;http_requests_total&lt;/code&gt;, a Prometheus &lt;strong&gt;counter metric&lt;/strong&gt; that counts the number of HTTP requests by status code, method, and other labels.&lt;/p&gt;
&lt;p&gt;You can get both the number of successful events and the total number of events from this metric, and define the SLI by selecting the &lt;strong&gt;Ratio&lt;/strong&gt; option in the Grafana SLO wizard:&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Ratio query builder&lt;/th&gt;
              &lt;th&gt;Value&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;Success metric&lt;/td&gt;
              &lt;td&gt;&lt;code&gt;http_requests_total{status!~&amp;quot;5..&amp;quot;}&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Metric for success requests&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;Total metric&lt;/td&gt;
              &lt;td&gt;&lt;code&gt;http_requests_total&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Metric for total requests&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;Grouping&lt;/td&gt;
              &lt;td&gt;&lt;em&gt;(leave empty)&lt;/em&gt;&lt;/td&gt;
              &lt;td&gt;Creates a single SLI dimension &lt;p&gt;&lt;em&gt;See the &lt;a href=&#34;/docs/grafana-cloud/alerting-and-irm/slo/sli-examples/multidimensional/&#34;&gt;multidimensional SLI example&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;Click &lt;strong&gt;Run queries&lt;/strong&gt; to generate the final SLI ratio query:&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;promql&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-promql&#34;&gt;(
  sum(rate(http_requests_total{status!~&amp;#34;5..&amp;#34;}[$__rate_interval] offset 2m))
  or 0 * sum(rate(http_requests_total[$__rate_interval] offset 2m))
)
/
sum(rate(http_requests_total[$__rate_interval] offset 2m))&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;h3 id=&#34;breakdown-of-the-ratio-sli-query&#34;&gt;Breakdown of the ratio SLI query&lt;/h3&gt;
&lt;p&gt;The auto-generated SLI query includes several common elements for building reliable SLIs and uses the ratio of successful event rates formula:&lt;/p&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;Success ratio = rate of successful events (over a period)
                /
                rate of total events (over a period)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;The SLI query result is a ratio between &lt;code&gt;0&lt;/code&gt; and &lt;code&gt;1&lt;/code&gt;, where &lt;code&gt;1&lt;/code&gt; means &lt;code&gt;100%&lt;/code&gt; of events were successful.&lt;/p&gt;
&lt;h4 id=&#34;rate-of-successful-events&#34;&gt;Rate of successful events&lt;/h4&gt;
&lt;p&gt;The following part of the query measures the rate of successful events over the rate interval:&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;promql&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-promql&#34;&gt;(
  sum(rate(http_requests_total{status!~&amp;#34;5..&amp;#34;}[$__rate_interval] offset 2m))
  or 0 * sum(rate(http_requests_total[$__rate_interval] offset 2m))
)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;http_requests_total{status!~&amp;quot;5..&amp;quot;}&lt;/code&gt;: Returns only successful requests.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;rate(...[$__rate_interval])&lt;/code&gt;: Calculates the per-second rate of successful requests over the recommended rate interval.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;offset 2m&lt;/code&gt;: Shifts the query two minutes into the past to account for scrape or data ingestion delays.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;sum(...)&lt;/code&gt;: Aggregates across all series (dimensions) to get the total success rate.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;or 0 * sum(rate(http_requests_total...))&lt;/code&gt;: Fallback for missing data. If the success metric returns no data, it returns 0 when dividing by total events.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;This numerator is then divided by the rate of total requests.&lt;/p&gt;
&lt;h4 id=&#34;rate-of-total-events&#34;&gt;Rate of total events&lt;/h4&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;promql&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-promql&#34;&gt;/
sum(rate(http_requests_total[$__rate_interval] offset 2m))&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;This query follows the &lt;code&gt;rate&lt;/code&gt; formula and applies the same &lt;code&gt;offset&lt;/code&gt; for alignment with the numerator (rate of successful events).&lt;/p&gt;
&lt;p&gt;The full query returns a ratio between 0 and 1, representing the proportion of successful requests. The Grafana SLO wizard displays the final SLI query and a graph of its results:&lt;/p&gt;
&lt;figure
    class=&#34;figure-wrapper figure-wrapper__lightbox w-100p &#34;
    style=&#34;max-width: 676px;&#34;
    itemprop=&#34;associatedMedia&#34;
    itemscope=&#34;&#34;
    itemtype=&#34;http://schema.org/ImageObject&#34;
  &gt;&lt;a
        class=&#34;lightbox-link&#34;
        href=&#34;/media/docs/grafana-cloud/slo/screenshot-http-availability-sli.png&#34;
        itemprop=&#34;contentUrl&#34;
      &gt;&lt;div class=&#34;img-wrapper w-100p h-auto&#34;&gt;&lt;img
          class=&#34;lazyload &#34;
          data-src=&#34;/media/docs/grafana-cloud/slo/screenshot-http-availability-sli.png&#34;data-srcset=&#34;/media/docs/grafana-cloud/slo/screenshot-http-availability-sli.png?w=320 320w, /media/docs/grafana-cloud/slo/screenshot-http-availability-sli.png?w=550 550w, /media/docs/grafana-cloud/slo/screenshot-http-availability-sli.png?w=750 750w, /media/docs/grafana-cloud/slo/screenshot-http-availability-sli.png?w=900 900w, /media/docs/grafana-cloud/slo/screenshot-http-availability-sli.png?w=1040 1040w, /media/docs/grafana-cloud/slo/screenshot-http-availability-sli.png?w=1240 1240w, /media/docs/grafana-cloud/slo/screenshot-http-availability-sli.png?w=1920 1920w&#34;data-sizes=&#34;auto&#34;alt=&#34;Screenshot of the Grafana SLO wizard creating an SLI for HTTP availability&#34;width=&#34;676&#34;height=&#34;732&#34;/&gt;
        &lt;noscript&gt;
          &lt;img
            src=&#34;/media/docs/grafana-cloud/slo/screenshot-http-availability-sli.png&#34;
            alt=&#34;Screenshot of the Grafana SLO wizard creating an SLI for HTTP availability&#34;width=&#34;676&#34;height=&#34;732&#34;/&gt;
        &lt;/noscript&gt;&lt;/div&gt;&lt;/a&gt;&lt;/figure&gt;
&lt;p&gt;Note that you can also use the &lt;strong&gt;Advanced&lt;/strong&gt; SLI option to create the same SLI query directly.&lt;/p&gt;
&lt;h2 id=&#34;probe-availability-using-prometheus-summary&#34;&gt;Probe availability (using Prometheus Summary)&lt;/h2&gt;
&lt;p&gt;This example uses &lt;strong&gt;Synthetic Monitoring probes&lt;/strong&gt;, such as local probes or &lt;a href=&#34;/docs/grafana-cloud/testing/synthetic-monitoring/create-checks/public-probes/&#34;&gt;Grafana Cloud probes&lt;/a&gt;, to verify service availability.&lt;/p&gt;
&lt;p&gt;The process is as follows:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Configure a synthetic check from one or more probe locations that continuously verify system availability.&lt;/p&gt;
&lt;p&gt;The check runs regularly, based on the configured frequency, and stores its results in Prometheus.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Define an SLO whose SLI queries the Prometheus probe results.&lt;/p&gt;
&lt;p&gt;Grafana SLO then evaluates the SLI query and reports the SLO compliance.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;This example uses the &lt;a href=&#34;/docs/grafana-cloud/testing/synthetic-monitoring/create-checks/checks/#common-check-metrics&#34;&gt;&lt;code&gt;probe_all_success&lt;/code&gt;&lt;/a&gt; metric, a summary metric that tracks whether the probe succeeded.&lt;/p&gt;
&lt;p&gt;Prometheus summary metrics expose additional &lt;code&gt;*_sum&lt;/code&gt; and &lt;code&gt;*_count&lt;/code&gt; series. You can use these to get the number of successful events and the total number of events, and define the SLI using the &lt;strong&gt;Ratio&lt;/strong&gt; option in the Grafana SLO wizard:&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Ratio query builder&lt;/th&gt;
              &lt;th&gt;Value&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;Success metric&lt;/td&gt;
              &lt;td&gt;&lt;code&gt;probe_all_success_sum{job=&amp;quot;&amp;lt;JOB_NAME&amp;gt;&amp;quot;}&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Number of successful probes&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;Total metric&lt;/td&gt;
              &lt;td&gt;&lt;code&gt;probe_all_success_count{job=&amp;quot;&amp;lt;JOB_NAME&amp;gt;&amp;quot;}&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Total number of probe executions&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;Grouping&lt;/td&gt;
              &lt;td&gt;&lt;em&gt;(leave empty)&lt;/em&gt;&lt;/td&gt;
              &lt;td&gt;Creates a single SLI dimension &lt;p&gt;&lt;em&gt;See the &lt;a href=&#34;/docs/grafana-cloud/alerting-and-irm/slo/sli-examples/multidimensional/&#34;&gt;multidimensional SLI example&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;Click &lt;strong&gt;Run queries&lt;/strong&gt; to generate the final SLI ratio query:&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;promql&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-promql&#34;&gt;(
  sum(rate(probe_all_success_sum{job=&amp;#34;&amp;lt;JOB_NAME&amp;gt;&amp;#34;}[$__rate_interval] offset 2m))
  or 0 * sum(rate(probe_all_success_count{job=&amp;#34;&amp;lt;JOB_NAME&amp;gt;&amp;#34;}[$__rate_interval] offset 2m))
)
/
sum(rate(probe_all_success_count{job=&amp;#34;&amp;lt;JOB_NAME&amp;gt;&amp;#34;}[$__rate_interval] offset 2m))&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;The SLI query returns a ratio between 0 and 1, where 1 means 100% of probe executions were successful.&lt;/p&gt;
&lt;p&gt;This example works exactly like the HTTP availability example. To learn why the SLI is formed this way and how it works, refer to the &lt;a href=&#34;#breakdown-of-the-ratio-sli-query&#34;&gt;breakdown of the ratio SLI query&lt;/a&gt; .&lt;/p&gt;
&lt;h2 id=&#34;probe-availability-using-prometheus-gauge&#34;&gt;Probe availability (using Prometheus Gauge)&lt;/h2&gt;
&lt;p&gt;Sometimes, a binary gauge metric is used to track successes, such as the &lt;a href=&#34;/docs/grafana-cloud/testing/synthetic-monitoring/create-checks/checks/#common-check-metrics&#34;&gt;&lt;code&gt;probe_success&lt;/code&gt;&lt;/a&gt; metric.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;probe_success&lt;/code&gt; is &lt;code&gt;1&lt;/code&gt; on success.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;probe_success&lt;/code&gt; is &lt;code&gt;0&lt;/code&gt; on failure.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;In the SLO wizard, the &lt;strong&gt;Ratio&lt;/strong&gt; option expects a counter metric and cannot generate the correct ratio SLI for this case. Use the &lt;strong&gt;Advanced&lt;/strong&gt; query option instead.&lt;/p&gt;
&lt;p&gt;Define an SLI that returns the ratio of successes, represented as a value between 0 and 1, as in the previous examples. You can use the ratio of successful events formula for this SLI:&lt;/p&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;Success ratio = number of successful events (over a period)
                /
                total number of events (over a period)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;The SLI can then be defined as follows:&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;promql&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-promql&#34;&gt;# `sum_over_time` sums the 1s to calculate the number of successful probes
sum(sum_over_time(probe_success{job=&amp;#34;&amp;lt;JOB_NAME&amp;gt;&amp;#34;}[$__interval]))
/
sum(count_over_time(probe_success{job=&amp;#34;&amp;lt;JOB_NAME&amp;gt;&amp;#34;}[$__interval]))
# `count_over_time` counts the total number of probe executions (1=success, 0=failure)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;probe_success{job=&amp;quot;&amp;lt;JOB_NAME&amp;gt;&amp;quot;}&lt;/code&gt;: Returns probe results for the specified job. Each sample is either &lt;code&gt;1&lt;/code&gt; (success) or &lt;code&gt;0&lt;/code&gt; (failure).&lt;/li&gt;
&lt;li&gt;&lt;code&gt;sum_over_time(...[$__interval])&lt;/code&gt;: Sums the values of successful probes over the given interval; failed probes are counted as &lt;code&gt;0&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;count_over_time(...[$__interval])&lt;/code&gt;: Counts all probe executions in the given interval, including both successes (&lt;code&gt;1&lt;/code&gt;) and failures (&lt;code&gt;0&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;&lt;code&gt;sum(...)&lt;/code&gt;: Aggregates across all series (dimensions) to get the total number of successful probes and total probe executions.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Like the other SLI examples, this SLI returns a value between &lt;code&gt;0&lt;/code&gt; and &lt;code&gt;1&lt;/code&gt;, representing the ratio of successful executions.&lt;/p&gt;


&lt;div class=&#34;admonition admonition-note&#34;&gt;&lt;blockquote&gt;&lt;p class=&#34;title text-uppercase&#34;&gt;Note&lt;/p&gt;&lt;p&gt;&lt;a href=&#34;/docs/grafana-cloud/connect-externally-hosted/data-sources/prometheus/template-variables/#use-__rate_interval&#34;&gt;&lt;code&gt;$__rate_interval&lt;/code&gt;&lt;/a&gt; is recommended for calculating &lt;code&gt;rate()&lt;/code&gt; in other examples. When you use other &lt;code&gt;_over_time()&lt;/code&gt; functions that don&amp;rsquo;t require at least two data points, it&amp;rsquo;s better to use &lt;code&gt;$__interval&lt;/code&gt; to achieve finer error budget resolution by evaluating SLIs at smaller time intervals.&lt;/p&gt;&lt;/blockquote&gt;&lt;/div&gt;

&lt;h2 id=&#34;availability-using-failure-metric&#34;&gt;Availability using failure metric&lt;/h2&gt;
&lt;p&gt;Sometimes, you might have a metric that counts failures instead of successes, because your instrumentation doesn&amp;rsquo;t use a single metric with a label indicating success or failure.&lt;/p&gt;
&lt;p&gt;For example, you may only have the following counters:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;failure_total&lt;/code&gt;: Counts failed requests or operations.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;all_total&lt;/code&gt;: Counts all requests or operations.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;In this case, you can calculate availability by subtracting failures from the total:&lt;/p&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;Success ratio = (total events - failed events)
                /
                total events&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Avoid using &lt;code&gt;1 - (&amp;lt;failure rate&amp;gt; / &amp;lt;total rate&amp;gt;)&lt;/code&gt; because the SLI can&amp;rsquo;t be parsed as a ratio-like query.&lt;/p&gt;
&lt;p&gt;In the Grafana SLO wizard, use the &lt;strong&gt;Advanced&lt;/strong&gt; option:&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;promql&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-promql&#34;&gt;# rate of successful events
(
  sum(rate(all_total[$__rate_interval]))
  -
  sum(rate(failure_total[$__rate_interval]))
)
/
sum(rate(all_total[$__rate_interval]))
# rate of total events&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;The SLI query result is still the same: a ratio between 0 and 1, where 1 means 100% of events were successful.&lt;/p&gt;
]]></content><description>&lt;h1 id="sli-example-for-availability">SLI example for availability&lt;/h1>
&lt;p>This guide provides examples to show how to define &lt;strong>availability SLIs&lt;/strong> based on successful HTTP responses and probe results. The examples explain various methods to define SLIs using distinct Prometheus metric types.&lt;/p></description></item><item><title>SLI example for latency</title><link>https://grafana.com/docs/plugins/grafana-slo-app/v1.65.0+c3f6e740273a3d27df7357f42c2234d42c03bb31/sli-examples/latency/</link><pubDate>Sat, 04 Apr 2026 20:10:38 +0000</pubDate><guid>https://grafana.com/docs/plugins/grafana-slo-app/v1.65.0+c3f6e740273a3d27df7357f42c2234d42c03bb31/sli-examples/latency/</guid><content><![CDATA[&lt;h1 id=&#34;sli-example-for-latency&#34;&gt;SLI example for latency&lt;/h1&gt;
&lt;p&gt;This guide provides examples of how to define latency SLIs using different Prometheus metric types. The basic SLO example for demonstration purposes is as follows:&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;SLI category&lt;/th&gt;
              &lt;th&gt;SLI description&lt;/th&gt;
              &lt;th&gt;Target&lt;/th&gt;
              &lt;th&gt;Time window&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;Latency&lt;/td&gt;
              &lt;td&gt;Requests respond within 2 seconds&lt;/td&gt;
              &lt;td&gt;99%&lt;/td&gt;
              &lt;td&gt;28d&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;The SLI in this example includes all requests, and the SLO defines the target percentage.&lt;/p&gt;
&lt;p&gt;When possible, &lt;strong&gt;avoid using percentiles in SLIs&lt;/strong&gt;, such as &lt;em&gt;95th percentile latency&lt;/em&gt; with a &lt;em&gt;99% target&lt;/em&gt;, to maintain simplicity and consistency across SLO types. Refer to &lt;a href=&#34;https://cloud.google.com/blog/products/gcp/building-good-slos-cre-life-lessons&#34; target=&#34;_blank&#34; rel=&#34;noopener noreferrer&#34;&gt;Building good SLOs—CRE life lessons&lt;/a&gt; from Google Cloud for more on this topic.&lt;/p&gt;
&lt;p&gt;Before you begin, read the &lt;a href=&#34;/docs/grafana-cloud/alerting-and-irm/slo/sli-examples/availability/&#34;&gt;SLI availability examples&lt;/a&gt; to understand how SLIs are defined in Grafana SLO:&lt;/p&gt;


&lt;div class=&#34;admonition admonition-note&#34;&gt;&lt;blockquote&gt;&lt;p class=&#34;title text-uppercase&#34;&gt;Note&lt;/p&gt;&lt;p&gt;Grafana expects SLIs to parse as a ratio-like query: &lt;code&gt;numerator / denominator&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;The &lt;strong&gt;SLI query result must return a ratio between 0 and 1&lt;/strong&gt;, where 1 means 100% of events were successful. This is required to evaluate whether the SLI meets the SLO target.&lt;/p&gt;&lt;/blockquote&gt;&lt;/div&gt;

&lt;figure
    class=&#34;figure-wrapper figure-wrapper__lightbox w-100p &#34;
    style=&#34;max-width: 1292px;&#34;
    itemprop=&#34;associatedMedia&#34;
    itemscope=&#34;&#34;
    itemtype=&#34;http://schema.org/ImageObject&#34;
  &gt;&lt;a
        class=&#34;lightbox-link&#34;
        href=&#34;/media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png&#34;
        itemprop=&#34;contentUrl&#34;
      &gt;&lt;div class=&#34;img-wrapper w-100p h-auto&#34;&gt;&lt;img
          class=&#34;lazyload &#34;
          data-src=&#34;/media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png&#34;data-srcset=&#34;/media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=320 320w, /media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=550 550w, /media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=750 750w, /media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=900 900w, /media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=1040 1040w, /media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=1240 1240w, /media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png?w=1920 1920w&#34;data-sizes=&#34;auto&#34;alt=&#34;Screenshot of the graph result of an SLI ratio&#34;width=&#34;1292&#34;height=&#34;516&#34;/&gt;
        &lt;noscript&gt;
          &lt;img
            src=&#34;/media/docs/grafana-cloud/slo/screenshot-sli-ratio-example.png&#34;
            alt=&#34;Screenshot of the graph result of an SLI ratio&#34;width=&#34;1292&#34;height=&#34;516&#34;/&gt;
        &lt;/noscript&gt;&lt;/div&gt;&lt;/a&gt;&lt;/figure&gt;
&lt;h2 id=&#34;probe-latency-using-prometheus-gauge&#34;&gt;Probe latency (using Prometheus Gauge)&lt;/h2&gt;
&lt;p&gt;This example uses the &lt;a href=&#34;/docs/grafana-cloud/testing/synthetic-monitoring/create-checks/checks/#common-check-metrics&#34;&gt;&lt;code&gt;probe_duration_seconds&lt;/code&gt;&lt;/a&gt; metric from Synthetic Monitoring probes to verify public latency. For details on how Synthetic Monitoring probes work, see the &lt;a href=&#34;/docs/grafana-cloud/alerting-and-irm/slo/sli-examples/availability/&#34;&gt;SLI availability examples using probes&lt;/a&gt;.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Metric&lt;/th&gt;
              &lt;th&gt;Type&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;probe_duration_seconds&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Gauge&lt;/td&gt;
              &lt;td&gt;How long the probe took to complete in seconds&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;In the Grafana SLO wizard, you can create SLIs using two options:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Ratio query builder&lt;/strong&gt;: Enter counter metrics for successful and total events.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Advanced&lt;/strong&gt;: Enter the ratio SLI query directly.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Because &lt;code&gt;probe_duration_seconds&lt;/code&gt; is not a counter metric, choose the &lt;strong&gt;Advanced&lt;/strong&gt; option to create the SLI query.&lt;/p&gt;
&lt;p&gt;SLIs are defined as ratio-like queries, either as the &lt;strong&gt;ratio of successful events&lt;/strong&gt; or the &lt;strong&gt;ratio of successful event rates&lt;/strong&gt;:&lt;/p&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;# ratio of successful event rates formula
Success ratio = rate of successful events (over a period)
                /  
                rate of total events (over a period)

# ratio of successful events formula
Success ratio = number of successful events (over a period)
                /  
                total number of events (over a period)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;With gauge metrics, you can implement the &lt;strong&gt;ratio of successful events&lt;/strong&gt; formula as follows:&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;promql&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-promql&#34;&gt;# number of successful probe requests over the interval
sum(
  count_over_time(
    (probe_duration_seconds{job=&amp;#34;&amp;lt;JOB_NAME&amp;gt;&amp;#34;} &amp;lt; 2)[$__interval:]
  )
)
/
# number of total probe requests over the interval
sum(
  count_over_time(
    probe_duration_seconds{job=&amp;#34;&amp;lt;JOB_NAME&amp;gt;&amp;#34;}[$__interval:]
  )
)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Here&amp;rsquo;s the breakdown of the numerator query:&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;promql&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-promql&#34;&gt;# number of successful probe requests over the interval
sum(
  count_over_time(
    (probe_duration_seconds{job=&amp;#34;&amp;lt;JOB_NAME&amp;gt;&amp;#34;} &amp;lt; 2)[$__interval:]
  )
)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;probe_duration_seconds{job=&amp;quot;&amp;lt;JOB_NAME&amp;gt;&amp;quot;} &amp;lt; 2&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Returns probe latency samples. The &lt;code&gt;&amp;lt; 2&lt;/code&gt; comparison filters samples where latency is within the SLI threshold (less than two seconds).&lt;/p&gt;
&lt;p&gt;The result is a binary series: &lt;code&gt;1&lt;/code&gt; for success and no sample for failure.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;[$__interval:]&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Runs the previous expression over the past &lt;code&gt;$__interval&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;Because &lt;code&gt;count_over_time&lt;/code&gt; works only on range vectors, it uses a subquery &lt;code&gt;[:]&lt;/code&gt; to produce a range vector containing all samples from that period.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;count_over_time(...)&lt;/code&gt;
Counts the number of samples in the previous query, the number of successful probe requests in the range vector.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Finally, &lt;code&gt;sum(...)&lt;/code&gt; aggregates across all series (dimensions).&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The numerator is then divided by the total number of probe requests over the same interval using a similar query:&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;promql&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-promql&#34;&gt;/
# number of total probe requests over the interval
sum(
  count_over_time(
    probe_duration_seconds{job=&amp;#34;&amp;lt;JOB_NAME&amp;gt;&amp;#34;}[$__interval:]
  )
)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;


&lt;div class=&#34;admonition admonition-note&#34;&gt;&lt;blockquote&gt;&lt;p class=&#34;title text-uppercase&#34;&gt;Note&lt;/p&gt;&lt;p&gt;&lt;a href=&#34;/docs/grafana-cloud/connect-externally-hosted/data-sources/prometheus/template-variables/#use-__rate_interval&#34;&gt;&lt;code&gt;$__rate_interval&lt;/code&gt;&lt;/a&gt; is recommended for calculating &lt;code&gt;rate()&lt;/code&gt; in other examples. When you use other &lt;code&gt;_over_time()&lt;/code&gt; functions that don&amp;rsquo;t require at least two data points, it&amp;rsquo;s better to use &lt;code&gt;$__interval&lt;/code&gt; to achieve finer error budget resolution by evaluating SLIs at smaller time intervals.&lt;/p&gt;&lt;/blockquote&gt;&lt;/div&gt;

&lt;div class=&#34;collapse&#34; x-data=&#34;app_collapse()&#34;&gt;
  &lt;button class=&#34;collapse-trigger&#34; @click=&#34;toggle()&#34;&gt;
    &lt;span class=&#34;body-large&#34;&gt;Alternative SLI query&lt;/span&gt;
    &lt;span class=&#34;collapse-trigger__icon&#34; :class=&#34;{ &#39;collapse-trigger__icon-open&#39; : open }&#34;&gt;
      
  &lt;svg width=&#34;27&#34; height=&#34;26&#34; viewBox=&#34;0 0 27 26&#34; fill=&#34;none&#34; xmlns=&#34;http://www.w3.org/2000/svg&#34;&gt;
&lt;path opacity=&#34;0.2&#34; d=&#34;M1.73047 12.8359C1.73047 19.4634 7.10305 24.8359 13.7305 24.8359C20.3579 24.8359 25.7305 19.4634 25.7305 12.8359C25.7305 6.20852 20.3579 0.835937 13.7305 0.835937C7.10305 0.835937 1.73047 6.20852 1.73047 12.8359Z&#34; stroke=&#34;black&#34; stroke-width=&#34;1.5&#34; stroke-linecap=&#34;round&#34; stroke-linejoin=&#34;round&#34;/&gt;
&lt;path d=&#34;M18.2344 12.8359L9.23438 12.8359&#34; stroke=&#34;black&#34; stroke-width=&#34;1.5&#34; stroke-linecap=&#34;round&#34; stroke-linejoin=&#34;round&#34;/&gt;
&lt;path d=&#34;M13.7344 8.33594L13.7344 17.3359&#34; stroke=&#34;black&#34; stroke-width=&#34;1.5&#34; stroke-linecap=&#34;round&#34; stroke-linejoin=&#34;round&#34;/&gt;
&lt;/svg&gt;


    &lt;/span&gt;
  &lt;/button&gt;
  &lt;div class=&#34;collapse-content&#34; x-ref=&#34;content&#34; hidden=&#34;until-found&#34;&gt;
    &lt;div class=&#34;collapse-content__inner&#34; x-ref=&#34;content-inner&#34;&gt;&lt;p&gt;Alternatively, the numerator can use &lt;code&gt;bool&lt;/code&gt; and &lt;code&gt;sum_over_time&lt;/code&gt;:&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;promql&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-promql&#34;&gt;# number of successful probe requests over the interval
# `bool` returns a binary 0/1 series and `sum_over_time` sums 1s for successes
sum(
    sum_over_time(
      (probe_duration_seconds{job=&amp;#34;&amp;lt;JOB_NAME&amp;gt;&amp;#34;} &amp;lt; bool 2)[$__interval:]
    )
)
/
# number of total probe requests over the interval
sum(
  count_over_time(
    probe_duration_seconds{job=&amp;#34;&amp;lt;JOB_NAME&amp;gt;&amp;#34;}[$__interval:]
  )
)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;h2 id=&#34;probe-latency-using-classic-histogram&#34;&gt;Probe latency (using Classic Histogram)&lt;/h2&gt;
&lt;p&gt;The  SLI example uses the &lt;a href=&#34;/docs/grafana-cloud/testing/synthetic-monitoring/create-checks/checks/#common-check-metrics&#34;&gt;&lt;code&gt;probe_all_duration_seconds&lt;/code&gt;&lt;/a&gt; histogram metric, whose SLI query is different.&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Metric&lt;/th&gt;
              &lt;th&gt;Type&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;&lt;code&gt;probe_all_duration_seconds&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Histogram&lt;/td&gt;
              &lt;td&gt;How long the probe took to complete in seconds&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;Classic histogram metrics in Prometheus store samples based on their value (&lt;em&gt;latency&lt;/em&gt; in this case) and expose additional series:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;*_count&lt;/code&gt;: Returns all samples for all latencies.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;*_bucket&lt;/code&gt;: Returns samples per configured buckets. The buckets for this metric are &lt;code&gt;0&lt;/code&gt;, &lt;code&gt;0.005&lt;/code&gt;, &lt;code&gt;0.1&lt;/code&gt;, &lt;code&gt;0.025&lt;/code&gt;, &lt;code&gt;0.05&lt;/code&gt;, &lt;code&gt;0.1&lt;/code&gt;, &lt;code&gt;0.25&lt;/code&gt;, &lt;code&gt;0.5&lt;/code&gt;, &lt;code&gt;1&lt;/code&gt;, &lt;code&gt;2.5&lt;/code&gt;, &lt;code&gt;5&lt;/code&gt;, &lt;code&gt;10&lt;/code&gt;, and &lt;code&gt;&#43;Inf&lt;/code&gt;.&lt;/p&gt;
&lt;figure
	    class=&#34;figure-wrapper figure-wrapper__lightbox w-100p &#34;
	    style=&#34;max-width: 557px;&#34;
	    itemprop=&#34;associatedMedia&#34;
	    itemscope=&#34;&#34;
	    itemtype=&#34;http://schema.org/ImageObject&#34;
	  &gt;&lt;a
	        class=&#34;lightbox-link&#34;
	        href=&#34;/media/docs/grafana-cloud/slo/screenshot-probe-all-duration-seconds-histogram.png&#34;
	        itemprop=&#34;contentUrl&#34;
	      &gt;&lt;div class=&#34;img-wrapper w-100p h-auto&#34;&gt;&lt;img
	          class=&#34;lazyload &#34;
	          data-src=&#34;/media/docs/grafana-cloud/slo/screenshot-probe-all-duration-seconds-histogram.png&#34;data-srcset=&#34;/media/docs/grafana-cloud/slo/screenshot-probe-all-duration-seconds-histogram.png?w=320 320w, /media/docs/grafana-cloud/slo/screenshot-probe-all-duration-seconds-histogram.png?w=550 550w, /media/docs/grafana-cloud/slo/screenshot-probe-all-duration-seconds-histogram.png?w=750 750w, /media/docs/grafana-cloud/slo/screenshot-probe-all-duration-seconds-histogram.png?w=900 900w, /media/docs/grafana-cloud/slo/screenshot-probe-all-duration-seconds-histogram.png?w=1040 1040w, /media/docs/grafana-cloud/slo/screenshot-probe-all-duration-seconds-histogram.png?w=1240 1240w, /media/docs/grafana-cloud/slo/screenshot-probe-all-duration-seconds-histogram.png?w=1920 1920w&#34;data-sizes=&#34;auto&#34;alt=&#34;Graph visualizing the different buckets of the `probe_all_duration_seconds` histogram metric&#34;width=&#34;557&#34;height=&#34;243&#34;/&gt;
	        &lt;noscript&gt;
	          &lt;img
	            src=&#34;/media/docs/grafana-cloud/slo/screenshot-probe-all-duration-seconds-histogram.png&#34;
	            alt=&#34;Graph visualizing the different buckets of the `probe_all_duration_seconds` histogram metric&#34;width=&#34;557&#34;height=&#34;243&#34;/&gt;
	        &lt;/noscript&gt;&lt;/div&gt;&lt;/a&gt;&lt;/figure&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;You can use a histogram metric to return the number of successful samples if the metric includes a bucket for the specific SLI threshold.&lt;/p&gt;
&lt;p&gt;However, &lt;code&gt;probe_all_duration_seconds&lt;/code&gt; does not include a bucket for &lt;code&gt;2s&lt;/code&gt;, and cannot be used to filter histogram samples at that threshold. For alternatives, refer to &lt;a href=&#34;#handle-a-threshold-not-available-as-a-bucket&#34;&gt;handle a threshold not available as a bucket&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;This example uses a different threshold (&lt;code&gt;2.5s&lt;/code&gt;) for demonstration purpose. Use the &lt;strong&gt;Ratio&lt;/strong&gt; option to build the SLI query as follows:&lt;/p&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Ratio query builder&lt;/th&gt;
              &lt;th&gt;Value&lt;/th&gt;
              &lt;th&gt;Description&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;Success metric&lt;/td&gt;
              &lt;td&gt;&lt;code&gt;probe_all_duration_seconds_bucket{job=&amp;quot;&amp;lt;JOB_NAME&amp;gt;&amp;quot;, le=&amp;quot;2.5&amp;quot;}&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Number of probes requests under 2.5s&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;Total metric&lt;/td&gt;
              &lt;td&gt;&lt;code&gt;probe_all_duration_seconds_count{job=&amp;quot;&amp;lt;JOB_NAME&amp;gt;&amp;quot;}&lt;/code&gt;&lt;/td&gt;
              &lt;td&gt;Total number of probe requests&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;Grouping&lt;/td&gt;
              &lt;td&gt;&lt;em&gt;(leave empty)&lt;/em&gt;&lt;/td&gt;
              &lt;td&gt;Creates a single SLI dimension &lt;p&gt;&lt;em&gt;See the &lt;a href=&#34;/docs/grafana-cloud/alerting-and-irm/slo/sli-examples/multidimensional/&#34;&gt;multidimensional SLI example&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;Click &lt;strong&gt;Run queries&lt;/strong&gt; to generate the final SLI ratio query:&lt;/p&gt;
&lt;figure
    class=&#34;figure-wrapper figure-wrapper__lightbox w-100p &#34;
    style=&#34;max-width: 668px;&#34;
    itemprop=&#34;associatedMedia&#34;
    itemscope=&#34;&#34;
    itemtype=&#34;http://schema.org/ImageObject&#34;
  &gt;&lt;a
        class=&#34;lightbox-link&#34;
        href=&#34;/media/docs/grafana-cloud/slo/screenshot-latency-sli-using-histogram.png&#34;
        itemprop=&#34;contentUrl&#34;
      &gt;&lt;div class=&#34;img-wrapper w-100p h-auto&#34;&gt;&lt;img
          class=&#34;lazyload &#34;
          data-src=&#34;/media/docs/grafana-cloud/slo/screenshot-latency-sli-using-histogram.png&#34;data-srcset=&#34;/media/docs/grafana-cloud/slo/screenshot-latency-sli-using-histogram.png?w=320 320w, /media/docs/grafana-cloud/slo/screenshot-latency-sli-using-histogram.png?w=550 550w, /media/docs/grafana-cloud/slo/screenshot-latency-sli-using-histogram.png?w=750 750w, /media/docs/grafana-cloud/slo/screenshot-latency-sli-using-histogram.png?w=900 900w, /media/docs/grafana-cloud/slo/screenshot-latency-sli-using-histogram.png?w=1040 1040w, /media/docs/grafana-cloud/slo/screenshot-latency-sli-using-histogram.png?w=1240 1240w, /media/docs/grafana-cloud/slo/screenshot-latency-sli-using-histogram.png?w=1920 1920w&#34;data-sizes=&#34;auto&#34;alt=&#34;Screenshot of the Grafana SLO wizard creating an SLI for latency using a Prometheus histogram metric&#34;width=&#34;668&#34;height=&#34;778&#34;/&gt;
        &lt;noscript&gt;
          &lt;img
            src=&#34;/media/docs/grafana-cloud/slo/screenshot-latency-sli-using-histogram.png&#34;
            alt=&#34;Screenshot of the Grafana SLO wizard creating an SLI for latency using a Prometheus histogram metric&#34;width=&#34;668&#34;height=&#34;778&#34;/&gt;
        &lt;/noscript&gt;&lt;/div&gt;&lt;/a&gt;&lt;/figure&gt;
&lt;p&gt;The auto-generated SLI implements the &lt;strong&gt;ratio of successful event rates&lt;/strong&gt; formula:&lt;/p&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;Success ratio = rate of successful events (over a period)
                /  
                rate of total events (over a period)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;The SLI query returns a ratio between 0 and 1, where 1 means 100% of events were successful.&lt;/p&gt;
&lt;p&gt;To learn why the auto-generated SLI is formed this way and how it works, refer to the &lt;a href=&#34;/docs/grafana-cloud/alerting-and-irm/slo/sli-examples/availability/#breakdown-of-the-ratio-sli-query&#34;&gt;breakdown of the ratio SLI query of the HTTP availability example&lt;/a&gt;.&lt;/p&gt;
&lt;h3 id=&#34;handle-a-threshold-not-available-as-a-bucket&#34;&gt;Handle a threshold not available as a bucket&lt;/h3&gt;
&lt;p&gt;With classic histograms, it&amp;rsquo;s common for your SLI threshold to not match an existing histogram bucket, as in this example:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;The SLI searches for responses under &lt;code&gt;2&lt;/code&gt; seconds.&lt;/li&gt;
&lt;li&gt;But the available buckets are configured for &lt;code&gt;1&lt;/code&gt; and &lt;code&gt;2.5&lt;/code&gt;, not &lt;code&gt;2&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;In this case, &lt;code&gt;probe_all_duration_seconds_bucket{job=&amp;quot;&amp;lt;JOB_NAME&amp;gt;&amp;quot;, le=&amp;quot;2&amp;quot;}&lt;/code&gt; does not work, and you should consider other approaches:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Add a bucket for your threshold&lt;/strong&gt;: If you control the instrumentation, update the histogram metric to include a bucket for the exact SLI threshold.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Use a fallback metric&lt;/strong&gt;: Check if a latency metric is available like in the &lt;a href=&#34;#probe-latency-using-prometheus-gauge&#34;&gt;previous Gauge example&lt;/a&gt;, or the native histogram example below.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Approximate using the nearest bucket&lt;/strong&gt;: Use the nearest higher or lower bucket. Document this clearly and adapt your SLO settings, as the SLO no longer match the intended SLI threshold.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&#34;http-latency-using-native-histogram&#34;&gt;HTTP latency (using Native Histogram)&lt;/h2&gt;
&lt;p&gt;In contrast to classic histograms, Prometheus native histograms can estimate the number of observations within arbitrary ranges—not just preconfigured buckets.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://prometheus.io/docs/prometheus/latest/querying/functions/#histogram_fraction&#34; target=&#34;_blank&#34; rel=&#34;noopener noreferrer&#34;&gt;&lt;code&gt;histogram_fraction()&lt;/code&gt;&lt;/a&gt; returns the estimated fraction of observations within a specified range, as a value between &lt;code&gt;0&lt;/code&gt; and &lt;code&gt;1&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;This function must be used with &lt;code&gt;rate()&lt;/code&gt; or &lt;code&gt;increase()&lt;/code&gt; to correctly handle counter resets. The SLI query should follow the &lt;strong&gt;ratio of successful event rates&lt;/strong&gt; formula:&lt;/p&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;# ratio of successful event rates formula
Success ratio = rate of successful events (over a period)
                /  
                rate of total events (over a period)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;This example uses &lt;code&gt;http_request_duration_seconds&lt;/code&gt;, a native histogram metric that records request latency. The complete SLI formula look like this:&lt;/p&gt;

&lt;div class=&#34;code-snippet &#34;&gt;&lt;div class=&#34;lang-toolbar&#34;&gt;
    &lt;span class=&#34;lang-toolbar__item lang-toolbar__item-active&#34;&gt;promql&lt;/span&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
    &lt;div class=&#34;lang-toolbar__border&#34;&gt;&lt;/div&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet &#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-promql&#34;&gt;(
histogram_fraction(0, 2, sum(rate(http_request_duration_seconds[$__rate_interval])))
*
histogram_count(         sum(rate(http_request_duration_seconds[$__rate_interval])))
)
/
histogram_count(         sum(rate(http_request_duration_seconds[$__rate_interval])))&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;rate(http_request_duration_seconds[$__rate_interval])&lt;/code&gt; calculates the per-second rate of observations over the interval.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;sum (...)&lt;/code&gt; aggregates across all dimensions (for example, all endpoints or status codes).&lt;/li&gt;
&lt;li&gt;&lt;code&gt;histogram_fraction(0, 2, ...)&lt;/code&gt; estimates the fraction of the request rate with latency between &lt;code&gt;0&lt;/code&gt; and &lt;code&gt;2&lt;/code&gt; seconds during the interval.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;histogram_count(...)&lt;/code&gt; returns the total request rate for the interval.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The query follows the ratio-style format (&lt;code&gt;numerator/denominator&lt;/code&gt;) of event-based SLIs:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Numerator&lt;/strong&gt;: &lt;code&gt;histogram_fraction(...) * histogram_count(...)&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Denominator&lt;/strong&gt;: &lt;code&gt;histogram_count(...)&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;It returns a ratio between &lt;code&gt;0&lt;/code&gt; and &lt;code&gt;1&lt;/code&gt;, where &lt;code&gt;1&lt;/code&gt; means &lt;code&gt;100%&lt;/code&gt; of requests were under &lt;code&gt;2&lt;/code&gt; seconds.&lt;/li&gt;
&lt;/ul&gt;


&lt;div class=&#34;admonition admonition-note&#34;&gt;&lt;blockquote&gt;&lt;p class=&#34;title text-uppercase&#34;&gt;Note&lt;/p&gt;&lt;p&gt;For consistency, this example uses &lt;code&gt;histogram_count(sum())&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;However, &lt;code&gt;sum(histogram_count())&lt;/code&gt; returns the same query result and is often more efficient.&lt;/p&gt;&lt;/blockquote&gt;&lt;/div&gt;

]]></content><description>&lt;h1 id="sli-example-for-latency">SLI example for latency&lt;/h1>
&lt;p>This guide provides examples of how to define latency SLIs using different Prometheus metric types. The basic SLO example for demonstration purposes is as follows:&lt;/p></description></item><item><title>Multidimensional SLI example</title><link>https://grafana.com/docs/plugins/grafana-slo-app/v1.65.0+c3f6e740273a3d27df7357f42c2234d42c03bb31/sli-examples/multidimensional/</link><pubDate>Sat, 04 Apr 2026 20:10:38 +0000</pubDate><guid>https://grafana.com/docs/plugins/grafana-slo-app/v1.65.0+c3f6e740273a3d27df7357f42c2234d42c03bb31/sli-examples/multidimensional/</guid><content><![CDATA[&lt;h1 id=&#34;multidimensional-sli-example&#34;&gt;Multidimensional SLI example&lt;/h1&gt;
&lt;p&gt;This guide explains what multidimensional SLIs are, how they work, and provides a basic example.&lt;/p&gt;
&lt;p&gt;Before you begin, read the &lt;a href=&#34;/docs/grafana-cloud/alerting-and-irm/slo/sli-examples/availability/&#34;&gt;SLI availability examples&lt;/a&gt; to understand how SLIs are defined in Grafana SLO:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Grafana supports event-based SLIs, which measure the &lt;strong&gt;ratio of successful events to total events&lt;/strong&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;The &lt;strong&gt;SLI query result must return a ratio between 0 and 1&lt;/strong&gt;, where &lt;code&gt;1&lt;/code&gt; means &lt;code&gt;100%&lt;/code&gt; of events were successful.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Grafana expects SLIs to be expressed as a ratio-like query: &lt;code&gt;numerator / denominator&lt;/code&gt;.&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;In the availability and latency SLI examples, some SLIs are calculated using the ratio of successful event rates formula:&lt;/p&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;Success ratio = rate of successful events over a period
                /  
                rate of total events over a period&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;However, this formula is not fully accurate, because Prometheus queries &lt;strong&gt;can return multiple series&lt;/strong&gt; (also called dimensions).&lt;/p&gt;
&lt;p&gt;In practice, the final SLIs use &lt;code&gt;sum(...)&lt;/code&gt; to aggregate results from all series. The formula looks more like:&lt;/p&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;Success ratio = sum(rate of successful events over a period)
                /  
                sum(rate of total events over a period)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Here, &lt;code&gt;sum(...)&lt;/code&gt; aggregates all potential dimensions (all distinct label values) in the numerator and denominator before the final ratio calculation.&lt;/p&gt;
&lt;p&gt;This type of SLI is referred to as a &lt;em&gt;roll-up&lt;/em&gt; SLI (or aggregated SLI). The following is an example using the &lt;strong&gt;Ratio query builder&lt;/strong&gt;:&lt;/p&gt;
&lt;figure
    class=&#34;figure-wrapper figure-wrapper__lightbox w-100p &#34;
    style=&#34;max-width: 678px;&#34;
    itemprop=&#34;associatedMedia&#34;
    itemscope=&#34;&#34;
    itemtype=&#34;http://schema.org/ImageObject&#34;
  &gt;&lt;a
        class=&#34;lightbox-link&#34;
        href=&#34;/media/docs/grafana-cloud/slo/multidimensional-rollup-sli-example.png&#34;
        itemprop=&#34;contentUrl&#34;
      &gt;&lt;div class=&#34;img-wrapper w-100p h-auto&#34;&gt;&lt;img
          class=&#34;lazyload &#34;
          data-src=&#34;/media/docs/grafana-cloud/slo/multidimensional-rollup-sli-example.png&#34;data-srcset=&#34;/media/docs/grafana-cloud/slo/multidimensional-rollup-sli-example.png?w=320 320w, /media/docs/grafana-cloud/slo/multidimensional-rollup-sli-example.png?w=550 550w, /media/docs/grafana-cloud/slo/multidimensional-rollup-sli-example.png?w=750 750w, /media/docs/grafana-cloud/slo/multidimensional-rollup-sli-example.png?w=900 900w, /media/docs/grafana-cloud/slo/multidimensional-rollup-sli-example.png?w=1040 1040w, /media/docs/grafana-cloud/slo/multidimensional-rollup-sli-example.png?w=1240 1240w, /media/docs/grafana-cloud/slo/multidimensional-rollup-sli-example.png?w=1920 1920w&#34;data-sizes=&#34;auto&#34;alt=&#34;Screenshot of the graph result of an SLI ratio&#34;width=&#34;678&#34;height=&#34;785&#34;/&gt;
        &lt;noscript&gt;
          &lt;img
            src=&#34;/media/docs/grafana-cloud/slo/multidimensional-rollup-sli-example.png&#34;
            alt=&#34;Screenshot of the graph result of an SLI ratio&#34;width=&#34;678&#34;height=&#34;785&#34;/&gt;
        &lt;/noscript&gt;&lt;/div&gt;&lt;/a&gt;&lt;/figure&gt;
&lt;h2 id=&#34;multidimensional-probe-example&#34;&gt;Multidimensional probe example&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Multidimensional SLIs&lt;/strong&gt; (SLIs evaluated across multiple label dimensions) use &lt;code&gt;sum by (&amp;lt;labels&amp;gt;)&lt;/code&gt; in both the numerator and denominator, producing multiple ratio series. For example:&lt;/p&gt;

&lt;div class=&#34;code-snippet code-snippet__mini&#34;&gt;&lt;div class=&#34;lang-toolbar__mini&#34;&gt;
    &lt;span class=&#34;code-clipboard&#34;&gt;
      &lt;button x-data=&#34;app_code_snippet()&#34; x-init=&#34;init()&#34; @click=&#34;copy()&#34;&gt;
        &lt;img class=&#34;code-clipboard__icon&#34; src=&#34;/media/images/icons/icon-copy-small-2.svg&#34; alt=&#34;Copy code to clipboard&#34; width=&#34;14&#34; height=&#34;13&#34;&gt;
        &lt;span&gt;Copy&lt;/span&gt;
      &lt;/button&gt;
    &lt;/span&gt;
  &lt;/div&gt;&lt;div class=&#34;code-snippet code-snippet__border&#34;&gt;
    &lt;pre data-expanded=&#34;false&#34;&gt;&lt;code class=&#34;language-none&#34;&gt;Success ratio = sum by (probe) (rate of successful probe executions)
                /  
                sum by (probe) (rate of total probe executions)&lt;/code&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;section class=&#34;expand-table-wrapper&#34;&gt;&lt;div class=&#34;button-div&#34;&gt;
      &lt;button class=&#34;expand-table-btn&#34;&gt;Expand table&lt;/button&gt;
    &lt;/div&gt;&lt;div class=&#34;responsive-table-wrapper&#34;&gt;
    &lt;table&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;Dimension&lt;/th&gt;
              &lt;th&gt;Success ratio per dimension&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;{probe=&amp;ldquo;NorthVirginia&amp;rdquo;}&lt;/td&gt;
              &lt;td&gt;0.9&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;{probe=&amp;ldquo;Spain&amp;rdquo;}&lt;/td&gt;
              &lt;td&gt;1&lt;/td&gt;
          &lt;/tr&gt;
          &lt;tr&gt;
              &lt;td&gt;{probe=&amp;ldquo;Tokyo&amp;rdquo;}&lt;/td&gt;
              &lt;td&gt;0.95&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
    &lt;/table&gt;
  &lt;/div&gt;
&lt;/section&gt;&lt;p&gt;The final SLI result is &lt;code&gt;0.9&lt;/code&gt;, equal to its equivalent roll-up SLI.&lt;/p&gt;
&lt;p&gt;In the final SLI calculation, all dimensions are aggregated, making it act as a roll-up SLI for SLO compliance.&lt;/p&gt;
&lt;p&gt;Continuing with the previous example, use the &lt;strong&gt;Grouping&lt;/strong&gt; function to define dimensions per &lt;code&gt;probe&lt;/code&gt;:&lt;/p&gt;
&lt;figure
    class=&#34;figure-wrapper figure-wrapper__lightbox w-100p &#34;
    style=&#34;max-width: 683px;&#34;
    itemprop=&#34;associatedMedia&#34;
    itemscope=&#34;&#34;
    itemtype=&#34;http://schema.org/ImageObject&#34;
  &gt;&lt;a
        class=&#34;lightbox-link&#34;
        href=&#34;/media/docs/grafana-cloud/slo/multidimensional-probe-sli-example.png&#34;
        itemprop=&#34;contentUrl&#34;
      &gt;&lt;div class=&#34;img-wrapper w-100p h-auto&#34;&gt;&lt;img
          class=&#34;lazyload &#34;
          data-src=&#34;/media/docs/grafana-cloud/slo/multidimensional-probe-sli-example.png&#34;data-srcset=&#34;/media/docs/grafana-cloud/slo/multidimensional-probe-sli-example.png?w=320 320w, /media/docs/grafana-cloud/slo/multidimensional-probe-sli-example.png?w=550 550w, /media/docs/grafana-cloud/slo/multidimensional-probe-sli-example.png?w=750 750w, /media/docs/grafana-cloud/slo/multidimensional-probe-sli-example.png?w=900 900w, /media/docs/grafana-cloud/slo/multidimensional-probe-sli-example.png?w=1040 1040w, /media/docs/grafana-cloud/slo/multidimensional-probe-sli-example.png?w=1240 1240w, /media/docs/grafana-cloud/slo/multidimensional-probe-sli-example.png?w=1920 1920w&#34;data-sizes=&#34;auto&#34;alt=&#34;Screenshot of the SLO wizard graph result of a multidimensional SLI&#34;width=&#34;683&#34;height=&#34;805&#34;/&gt;
        &lt;noscript&gt;
          &lt;img
            src=&#34;/media/docs/grafana-cloud/slo/multidimensional-probe-sli-example.png&#34;
            alt=&#34;Screenshot of the SLO wizard graph result of a multidimensional SLI&#34;width=&#34;683&#34;height=&#34;805&#34;/&gt;
        &lt;/noscript&gt;&lt;/div&gt;&lt;/a&gt;&lt;/figure&gt;
&lt;p&gt;Note that you can create multidimensional SLIs using either option in the Grafana SLO wizard: &lt;strong&gt;Ratio&lt;/strong&gt; or &lt;strong&gt;Advanced&lt;/strong&gt;.&lt;/p&gt;
&lt;h2 id=&#34;how-multidimensional-slis-work&#34;&gt;How multidimensional SLIs work&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;For SLO compliance evaluation, the SLI calculation for multidimensional and roll-up SLIs is exactly the same&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;However, Grafana SLO provides additional functionality to handle multidimensional SLIs:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Fast and slow burn alerts per dimension&lt;/strong&gt;. When enabled, Grafana SLO triggers fast-burn or slow-burn alerts whenever an individual dimension consumes the error budget quickly or slowly, respectively.&lt;/p&gt;
&lt;figure
	    class=&#34;figure-wrapper figure-wrapper__lightbox w-100p &#34;
	    style=&#34;max-width: 1498px;&#34;
	    itemprop=&#34;associatedMedia&#34;
	    itemscope=&#34;&#34;
	    itemtype=&#34;http://schema.org/ImageObject&#34;
	  &gt;&lt;a
	        class=&#34;lightbox-link captioned&#34;
	        href=&#34;/media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-alerts.png&#34;
	        itemprop=&#34;contentUrl&#34;
	      &gt;&lt;div class=&#34;img-wrapper w-100p h-auto&#34;&gt;&lt;img
	          class=&#34;lazyload mb-0&#34;
	          data-src=&#34;/media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-alerts.png&#34;data-srcset=&#34;/media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-alerts.png?w=320 320w, /media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-alerts.png?w=550 550w, /media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-alerts.png?w=750 750w, /media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-alerts.png?w=900 900w, /media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-alerts.png?w=1040 1040w, /media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-alerts.png?w=1240 1240w, /media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-alerts.png?w=1920 1920w&#34;data-sizes=&#34;auto&#34;alt=&#34;The SLO dashboard displays the list of multidimensional alerts&#34;width=&#34;1498&#34;height=&#34;667&#34;title=&#34;The SLO dashboard displays the list of multidimensional alerts&#34;/&gt;
	        &lt;noscript&gt;
	          &lt;img
	            src=&#34;/media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-alerts.png&#34;
	            alt=&#34;The SLO dashboard displays the list of multidimensional alerts&#34;width=&#34;1498&#34;height=&#34;667&#34;title=&#34;The SLO dashboard displays the list of multidimensional alerts&#34;/&gt;
	        &lt;/noscript&gt;&lt;/div&gt;&lt;figcaption class=&#34;w-100p caption text-gray-13  &#34;&gt;The SLO dashboard displays the list of multidimensional alerts&lt;/figcaption&gt;&lt;/a&gt;&lt;/figure&gt;


&lt;div class=&#34;admonition admonition-note&#34;&gt;&lt;blockquote&gt;&lt;p class=&#34;title text-uppercase&#34;&gt;Note&lt;/p&gt;&lt;p&gt;Multidimensional alerts are not triggered for overall SLO consumption, but only for the consumption of a particular dimension.&lt;/p&gt;
&lt;p&gt;To be alerted when the overall error budget is consumed, create a roll-up SLO that does not include the &lt;code&gt;sum/group by&lt;/code&gt; dimensions.&lt;/p&gt;&lt;/blockquote&gt;&lt;/div&gt;

&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Per-dimension SLO dashboard filtering&lt;/strong&gt;. The SLO dashboard allows filtering results and visualizing SLI consumption for each dimension.&lt;/p&gt;
&lt;figure
	    class=&#34;figure-wrapper figure-wrapper__lightbox w-100p &#34;
	    style=&#34;max-width: 898px;&#34;
	    itemprop=&#34;associatedMedia&#34;
	    itemscope=&#34;&#34;
	    itemtype=&#34;http://schema.org/ImageObject&#34;
	  &gt;&lt;a
	        class=&#34;lightbox-link&#34;
	        href=&#34;/media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-sli.png&#34;
	        itemprop=&#34;contentUrl&#34;
	      &gt;&lt;div class=&#34;img-wrapper w-100p h-auto&#34;&gt;&lt;img
	          class=&#34;lazyload &#34;
	          data-src=&#34;/media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-sli.png&#34;data-srcset=&#34;/media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-sli.png?w=320 320w, /media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-sli.png?w=550 550w, /media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-sli.png?w=750 750w, /media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-sli.png?w=900 900w, /media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-sli.png?w=1040 1040w, /media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-sli.png?w=1240 1240w, /media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-sli.png?w=1920 1920w&#34;data-sizes=&#34;auto&#34;alt=&#34;A screenshot of an SLO dashboard that displays SLI consumption per probe&#34;width=&#34;898&#34;height=&#34;736&#34;/&gt;
	        &lt;noscript&gt;
	          &lt;img
	            src=&#34;/media/docs/grafana-cloud/slo/slo-dashboard-with-multidimensional-sli.png&#34;
	            alt=&#34;A screenshot of an SLO dashboard that displays SLI consumption per probe&#34;width=&#34;898&#34;height=&#34;736&#34;/&gt;
	        &lt;/noscript&gt;&lt;/div&gt;&lt;/a&gt;&lt;/figure&gt;
&lt;/li&gt;
&lt;/ol&gt;


&lt;div class=&#34;admonition admonition-tip&#34;&gt;&lt;blockquote&gt;&lt;p class=&#34;title text-uppercase&#34;&gt;Tip&lt;/p&gt;&lt;p&gt;To learn more about how Grafana evaluates metrics with multiple label dimensions, see also &lt;a href=&#34;/docs/grafana-cloud/alerting-and-irm/alerting/best-practices/multi-dimensional-alerts/&#34;&gt;Multi-dimensional alert examples&lt;/a&gt;.&lt;/p&gt;&lt;/blockquote&gt;&lt;/div&gt;

]]></content><description>&lt;h1 id="multidimensional-sli-example">Multidimensional SLI example&lt;/h1>
&lt;p>This guide explains what multidimensional SLIs are, how they work, and provides a basic example.&lt;/p>
&lt;p>Before you begin, read the &lt;a href="/docs/grafana-cloud/alerting-and-irm/slo/sli-examples/availability/">SLI availability examples&lt;/a> to understand how SLIs are defined in Grafana SLO:&lt;/p></description></item></channel></rss>