Grafana’s alert page lets you silence alerts, but most people don’t realize it uses a specific API endpoint and requires a precise understanding of the alert state to work correctly.

Let’s see it in action. Imagine you have an alert firing for a critical service, say High CPU Usage on webserver-01.

Here’s a typical alert definition in Grafana:

{
  "annotations": {

    "summary": "High CPU usage on {{ $labels.instance }}"

  },
  "labels": {
    "severity": "critical",
    "instance": "webserver-01"
  },
  "state": "firing",
  "id": 123,
  "ruleId": 45,
  "alertname": "High CPU Usage",
  "created_at": "2023-10-27T10:00:00Z",
  "updated_at": "2023-10-27T10:30:00Z",
  "eval_time": "2023-10-27T10:30:00Z"
}

To silence this specific alert from the Grafana UI, you’d navigate to the "Alerts" section, find the High CPU Usage alert for webserver-01, and click the "Silence" button.

This action triggers an API call to Grafana’s backend, specifically targeting the /api/v1/alerts/silence endpoint. The UI constructs a JSON payload that looks something like this:

{
  "match": {
    "alertname": "High CPU Usage",
    "instance": "webserver-01"
  },
  "starts_at": "2023-10-27T10:35:00Z",
  "ends_at": "2023-10-27T11:35:00Z",
  "comment": "Investigating high CPU, temporary silence."
}

The match object is crucial. It tells Grafana which alerts this silence rule should apply to. It uses the labels associated with the alert. In this case, it’s matching alerts where alertname is High CPU Usage AND instance is webserver-01. The starts_at and ends_at fields define the duration of the silence, and comment provides context for why the silence was created.

Grafana stores these silences internally. When an alert comes in, Grafana checks if any active silence rules match its labels and are currently within their time window. If a match is found, the alert is effectively muted, and no notifications are sent, even if the alert condition is still met.

The power here is in the label matching. You can silence all alerts with severity: critical across all instances, or just a single specific alert by matching multiple labels. The UI abstracts this complexity, but understanding the underlying label matching is key to effective alert management. For instance, if you accidentally silence an alert with instance: webserver-* (using a wildcard, which isn’t directly supported in the UI’s basic silence but is via API), you might silence more than you intended. The UI enforces specific label-value pairs for clarity.

The starts_at and ends_at times are in UTC. If your Grafana server and your local machine are in different time zones, ensure you’re setting these correctly, or you might find your silence ends sooner or later than expected. The UI typically handles this conversion based on your browser’s locale, but it’s good to be aware of the underlying UTC values.

Many users overlook the comment field. This is a missed opportunity to document why an alert is silenced, which is invaluable for post-mortems or when a colleague needs to understand a past incident. A good comment can save hours of investigation later.

The true magic of this feature is its integration with the alert state. When you silence an alert, it doesn’t change the alert’s underlying state from "firing" to "resolved." The alert condition may still be met, and the alert will continue to show up in the "Alerts" list with a "Silenced" status overlay. This means you can still see that the problem exists, but you’re not being actively notified. This distinction is vital: silence is not resolution.

The next step is understanding how to programmatically manage these silences using the Grafana API, rather than relying solely on the UI.

Want structured learning?

Take the full Grafana course →