Grafana
Query metrics, logs, traces, manage dashboards, alerts, and on-call schedules
ObservabilityMonitoringDevOpsIncident Management
About
Query metrics, logs, traces, and profiles in Grafana Cloud or self-hosted Grafana, manage dashboards and alerts, and coordinate on-call schedules.
This server is appropriate for connecting to self-hosted instances of Grafana. If you’re using Grafana Cloud, we recommend using the Grafana Cloud MCP server.
Features
- Observability Data Queries: Query Prometheus metrics, Loki logs, Tempo traces, and Pyroscope profiles
- Dashboard Management: Search, view, create, update dashboards with full JSONPath support for efficient modifications
- Alerting: Manage alert rules, contact points, and alert groups with comprehensive monitoring capabilities
- Datasource Integration: List and interact with all configured datasources (Prometheus, Loki, Tempo, Pyroscope, etc.)
- Incident Management: Create, track, and manage incidents with timeline activities and drill incidents
- OnCall Management: Manage on-call schedules, shifts, users, and teams for incident response coordination
- Sift Investigations: Run automated investigations to find slow requests and error patterns in logs
- User & Organization Management: Manage teams, users, folders, and organizational resources
- Deeplink Generation: Generate direct URLs to dashboards, panels, and Explore queries
What you’ll need to connect
Required:
- Grafana URL: The URL of your Grafana instance (e.g., https://your-org.grafana.net for Grafana Cloud, or your self-hosted instance URL)
Authentication (choose one method):
- Service Account Token (Recommended): Generate a service account token from Administration > Service Accounts in Grafana. Make sure to grant the token the necessary permissions for the intended operations. This is the preferred authentication method for production use.
- Username & Password (Alternative): Use basic authentication with your Grafana username and password. Suitable for development or local instances.
Optional:
- Organization ID: Specify a particular organization ID for multi-org Grafana instances.
Configuration
Environment variables
| Variable | Description | Required |
|---|---|---|
GRAFANA_URL | The URL of your Grafana instance (e.g., https://your-org.grafana.net for Grafana Cloud, or your self-hosted instance URL) | Yes |
GRAFANA_SERVICE_ACCOUNT_TOKEN | (Recommended) Your Grafana service account token for API authentication. Generate from Administration > Service Accounts in Grafana. Requires appropriate permissions for intended operations. | No |
GRAFANA_USERNAME | (Optional) Your Grafana username for basic authentication. | No |
GRAFANA_PASSWORD | (Optional) Your Grafana password for basic authentication. | No |
GRAFANA_ORG_ID | (Optional) Your Grafana organization ID for multi-org support. | No |
Container runtime
- Image
ghcr.io/obot-platform/mcp-images/grafana:latest- Port
8080- Path
/mcp- Args
-t, streamable-http, --address, 0.0.0.0:8080