> ## Documentation Index
> Fetch the complete documentation index at: https://docs.rootly.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Grafana

> Connect Grafana to Rootly to ingest alert events and capture dashboard and panel snapshots during incidents through Genius workflows.

The Grafana integration connects Rootly with your Grafana instance in two directions. Grafana alert rules send events into Rootly as alerts, and incident workflows capture dashboard and panel snapshots so responders keep point-in-time visibility into your metrics without leaving the incident.

With the Grafana integration, you can:

* Receive Grafana alert events as Rootly alerts, routed to services, teams, or escalation policies
* Page Rootly on-call targets directly from Grafana alert rules
* Capture Grafana dashboard and panel snapshots from Genius workflows during incidents
* Attach snapshot links to incident timelines for post-incident review

## Before You Begin

Before setting up the integration, make sure you have:

* A Rootly account with permission to manage integrations
* A Grafana instance accessible over HTTPS
* Permission to create service accounts in Grafana
* Permission to configure contact points and alert rules in Grafana, if you plan to ingest alerts

<Info>
  Rootly requires a Grafana service account with an **Admin** role to create dashboard snapshots. Rootly recommends a dedicated service account so the integration does not break if an individual user leaves your organization.
</Info>

## Installation

<Steps>
  <Step title="Open the Grafana integration in Rootly" icon="plug">
    Navigate to the integrations page in Rootly and select **Grafana**.

    <Frame>
      <img alt="Grafana integration on the integrations page" src="https://mintcdn.com/rootly/B5LjEUer9bznbdgT/images/image-6.png?fit=max&auto=format&n=B5LjEUer9bznbdgT&q=85&s=9e29d8232dec49c7322180d2d793bb18" width="2708" height="1198" data-path="images/image-6.png" />
    </Frame>
  </Step>

  <Step title="Create a service account in Grafana" icon="user-shield">
    In your Grafana instance, navigate to **Administration > Service Accounts**.

    <Frame>
      <img alt="Grafana service accounts page" src="https://mintcdn.com/rootly/B5LjEUer9bznbdgT/images/image-5.png?fit=max&auto=format&n=B5LjEUer9bznbdgT&q=85&s=d4059fddd5c24c65c8c6bab7f9a39c8c" style={{ width: "44%" }} width="1254" height="1838" data-path="images/image-5.png" />
    </Frame>

    Select **Add service account** and create it with an **Admin** role.

    <Frame>
      <img alt="Service account role configuration" src="https://mintcdn.com/rootly/B5LjEUer9bznbdgT/images/image-8.png?fit=max&auto=format&n=B5LjEUer9bznbdgT&q=85&s=f85366121214cf9c654d21b2a794a0bb" style={{ width: "82%" }} width="2410" height="1294" data-path="images/image-8.png" />
    </Frame>

    <Warning>
      Grafana service accounts with roles lower than Admin cannot create snapshots. The integration will fail silently if the role is insufficient.
    </Warning>
  </Step>

  <Step title="Generate a service account token" icon="key">
    Open the service account and select **Add Service Account token**. Enter a display name, set the token expiration, and generate the token.

    <Frame>
      <img alt="Token generation form" src="https://mintcdn.com/rootly/B5LjEUer9bznbdgT/images/image-10.png?fit=max&auto=format&n=B5LjEUer9bznbdgT&q=85&s=544e8c3f42ac710898030a115e9299ef" width="2242" height="1240" data-path="images/image-10.png" />
    </Frame>

    <Warning>
      Copy the token immediately — Grafana will not show it again after you leave this page.
    </Warning>

    <Frame>
      <img alt="Copy service account token" src="https://mintcdn.com/rootly/B5LjEUer9bznbdgT/images/image-11.png?fit=max&auto=format&n=B5LjEUer9bznbdgT&q=85&s=0417110c7d728f604342088cdbcdad37" width="2402" height="1172" data-path="images/image-11.png" />
    </Frame>
  </Step>

  <Step title="Connect Grafana to Rootly" icon="link">
    Enter your Grafana **instance URL** and the **service account token** into the Rootly integration settings and save.

    <Info>
      The instance URL must use HTTPS. HTTP URLs are not accepted.
    </Info>

    <Frame>
      <img alt="Rootly Grafana integration settings" src="https://mintcdn.com/rootly/B5LjEUer9bznbdgT/images/image-12.png?fit=max&auto=format&n=B5LjEUer9bznbdgT&q=85&s=450b8104981d908e355f9b523438f26b" width="2262" height="1120" data-path="images/image-12.png" />
    </Frame>
  </Step>
</Steps>

## Ingest Grafana Alerts

Grafana sends alert events into Rootly through a webhook contact point. Once alerts are flowing, alert workflows can create incidents, notify Slack channels, or page on-call targets.

<Warning>
  Install the integration before configuring the contact point. The webhook secret is generated during installation and is required for authentication.
</Warning>

### Configure a Webhook Contact Point

<Steps>
  <Step title="Navigate to Contact Points in Grafana" icon="bell">
    Log into your Grafana instance and navigate to **Alerting > Contact points**.

    <Frame>
      <img alt="Grafana contact points page" src="https://mintcdn.com/rootly/DEGWl8qg20zbzmSF/images/integrations/grafana/alerts/images-1.webp?fit=max&auto=format&n=DEGWl8qg20zbzmSF&q=85&s=8a6a17ad887b9ee25a6e24984420edb6" width="902" height="719" data-path="images/integrations/grafana/alerts/images-1.webp" />
    </Frame>

    Select **+ Add contact point**.

    <Frame>
      <img alt="Add contact point button" src="https://mintcdn.com/rootly/DEGWl8qg20zbzmSF/images/integrations/grafana/alerts/images-2.webp?fit=max&auto=format&n=DEGWl8qg20zbzmSF&q=85&s=4d63befcdfe4368dd1c760ba2edeb999" width="871" height="237" data-path="images/integrations/grafana/alerts/images-2.webp" />
    </Frame>
  </Step>

  <Step title="Configure the contact point" icon="webhook">
    Fill in the contact point details:

    * **Name** — give the contact point a descriptive name
    * **Integration** — select **Webhook**
    * **HTTP Method** — select **POST**

    <Frame>
      <img alt="Contact point configuration form" src="https://mintcdn.com/rootly/DEGWl8qg20zbzmSF/images/integrations/grafana/alerts/images-3.webp?fit=max&auto=format&n=DEGWl8qg20zbzmSF&q=85&s=ae3154408514b09af94a9b8fa7cf2954" width="888" height="950" data-path="images/integrations/grafana/alerts/images-3.webp" />
    </Frame>
  </Step>

  <Step title="Set the webhook URL" icon="link">
    The URL format depends on whether you want a general alert or want to page an on-call target.

    **For a general alert** (appears in Rootly Alerts, does not page anyone):

    ```text theme={null}
    https://webhooks.rootly.com/webhooks/incoming/grafana_webhooks/?secret=<your-secret>
    ```

    <Frame>
      <img alt="General alert webhook URL" src="https://mintcdn.com/rootly/DEGWl8qg20zbzmSF/images/integrations/grafana/alerts/images-4.webp?fit=max&auto=format&n=DEGWl8qg20zbzmSF&q=85&s=9f6875700febed17f753b293e49bb5de" width="884" height="661" data-path="images/integrations/grafana/alerts/images-4.webp" />
    </Frame>

    **To page a Rootly on-call target**, append a notification target to the URL:

    ```text theme={null}
    https://webhooks.rootly.com/webhooks/incoming/grafana_webhooks/notify/<resource_type>/<resource_id>?secret=<your-secret>
    ```

    <Info>
      Supported resource types are `User`, `Group` (team), `EscalationPolicy`, and `Service`. The resource ID can be found by editing the resource in Rootly.
    </Info>

    <Frame>
      <img alt="On-call paging webhook URL" src="https://mintcdn.com/rootly/DEGWl8qg20zbzmSF/images/integrations/grafana/alerts/images-5.webp?fit=max&auto=format&n=DEGWl8qg20zbzmSF&q=85&s=ca721176a3e34742e98a65a0df644f2b" width="896" height="1079" data-path="images/integrations/grafana/alerts/images-5.webp" />
    </Frame>

    Your webhook URL and secret are available in Rootly under **Integrations > Grafana > Configure**.
  </Step>

  <Step title="Test and save the contact point" icon="circle-check">
    Select **Test** to send a test alert to Rootly. A test alert should appear on your [Rootly Alerts page](https://rootly.com/account/alerts).

    <Frame>
      <img alt="Test alert result in Rootly" src="https://mintcdn.com/rootly/DEGWl8qg20zbzmSF/images/integrations/grafana/alerts/images-6.webp?fit=max&auto=format&n=DEGWl8qg20zbzmSF&q=85&s=def850922e3ceb6a1b3abc8ac9850c48" width="901" height="316" data-path="images/integrations/grafana/alerts/images-6.webp" />
    </Frame>

    Once the test succeeds, select **Save contact point**.
  </Step>
</Steps>

### Attach the Contact Point to Alert Rules

A contact point only receives alerts when it is attached to an active alert rule.

Navigate to **Alerting > Alert rules** and select **+ New alert rule**, or edit an existing rule. In the rule configuration, set the **Contact point** to the one you just created.

<Frame>
  <img alt="Attaching contact point to an alert rule" src="https://mintcdn.com/rootly/DEGWl8qg20zbzmSF/images/integrations/grafana/alerts/images-7.webp?fit=max&auto=format&n=DEGWl8qg20zbzmSF&q=85&s=2d61c0e762b31a126dde68acd2f547d8" width="899" height="723" data-path="images/integrations/grafana/alerts/images-7.webp" />
</Frame>

<Tip>
  You can attach the same Rootly contact point to multiple alert rules. Use different contact point URLs (with different notification targets) to route different rules to different on-call targets.
</Tip>

<Frame>
  <img alt="Alert rule with contact point configured" src="https://mintcdn.com/rootly/DEGWl8qg20zbzmSF/images/integrations/grafana/alerts/images-8.webp?fit=max&auto=format&n=DEGWl8qg20zbzmSF&q=85&s=ecb356c84576765ed6811e2b8f48f92c" width="905" height="1510" data-path="images/integrations/grafana/alerts/images-8.webp" />
</Frame>

### How Alerts Are Mapped

Rootly extracts the following fields from each Grafana webhook payload:

* **Summary** — the `title` field from the Grafana alert payload
* **External ID** — the `ruleId`, used to deduplicate alerts from the same rule
* **External URL** — the `ruleUrl`, linking back to the Grafana alert rule
* **Labels** — all key-value pairs from `commonLabels` are attached as Rootly alert labels, making them available for routing and filtering

<Info>
  Grafana `commonLabels` map directly to Rootly alert labels. You can use these labels in alert routing rules and workflow conditions to control how different Grafana alerts are handled.
</Info>

## Workflow Actions

Once the integration is connected, two new tasks are available in your Genius workflows:

* **Capture Grafana Dashboard Snapshot** — captures a snapshot of a full dashboard
* **Capture Grafana Panel Snapshot** — captures a snapshot of a specific panel

<Info>
  Snapshots are point-in-time captures. The snapshot link is attached to the incident timeline so you can reference exactly what your dashboards looked like when the incident occurred.
</Info>

## Troubleshooting

<AccordionGroup>
  <Accordion title="No alerts are appearing in Rootly after a Grafana alert fires" icon="circle-exclamation">
    Confirm the contact point is correctly attached to the alert rule that fired. Verify the webhook URL is correct and the secret matches what is shown in your Rootly Grafana integration settings. Use the **Test** button in the contact point configuration to confirm delivery.
  </Accordion>

  <Accordion title="The test alert works but real alerts do not appear" icon="triangle-exclamation">
    Check that the alert rule is in a firing state and that the contact point is set as the notification destination for that rule. Grafana alert rules that use notification policies rather than direct contact point assignment may route differently than expected.
  </Accordion>

  <Accordion title="On-call paging is not triggering" icon="bell-slash">
    Verify that the `resource_type` and `resource_id` in the notification target URL are correct and that the resource exists in Rootly. Ensure the resource type is one of `User`, `Group`, `EscalationPolicy`, or `Service`.
  </Accordion>

  <Accordion title="Snapshots are not being captured" icon="image-slash">
    Confirm the Grafana service account has the **Admin** role — lower roles cannot create snapshots and the workflow task fails silently. Check that the instance URL uses HTTPS and that the service account token has not expired.
  </Accordion>
</AccordionGroup>

## Uninstall

To remove the Grafana integration, open the integrations panel in Rootly and select **Configure > Delete**.

## Related Resources

* [Alert workflows](/workflows/alert-workflows)
* [Alert routing](/alerts/alert-routing)
* [Integrations overview](/integrations/overview)
