This is documentation for the next version of Grafana documentation. For the latest stable release, go to the latest version.

Grafana Cloud Enterprise Open source

AI tools in Grafana OSS

If you’re a self-managed Grafana user, you have the following AI tools available to interact with Grafana:

Grafana Assistant is the Grafana AI agent, built into Grafana. Assistant brings a purpose-built LLM into Grafana so operators, developers, and SREs can troubleshoot issues, manage dashboards, and answer product questions in plain language.

  • In self-managed Grafana the Assistant app runs in your own deployment but connects to a Grafana Cloud Assistant backend, with a reduced feature set.
  • Assistant is billed per token consumed, including requests made through gcx and MCP servers (although Assistant in MCP is disabled by default).

MCP servers let an external AI client (for example Claude, Cursor, or VS Code with Copilot) call Grafana as a set of tools that cover common tasks: dashboards and folders, data sources (Prometheus, Loki, and others), alerting, incidents, OnCall, and more.

  • A model picks which tool to use based on the tool description, and calls the tool with structured arguments. Grafana runs it under normal identity and RBAC, and the structured result goes back to the model for its next step.
  • Grafana offers two servers: Cloud MCP (hosted by Grafana) and OSS MCP (you run it).

gcx is an AI-native command-line tool that gives you or your AI agent structured access to Grafana (dashboards, folders, alert rules, data sources) and Grafana Cloud products such as Synthetic Monitoring, k6, Fleet Management, Incidents, and Adaptive Telemetry. Use it to script deterministic JSON or YAML output, defined errors, and predictable exit codes.

Explore

Side-by-side comparison

This table summarizes the main points for each tool:

Grafana AssistantCloud MCPOSS MCPgcx
What it isBuilt-in Grafana AI agentGrafana-hosted MCP endpoint for external AI clientsSelf-run MCP server (mcp-grafana)CLI for Grafana and Grafana Cloud
Who drives itA person, inside GrafanaA person or an agent, through an MCP clientA person or an agent, through an MCP clientA person, a script, or a coding agent issuing explicit commands
SetupIn Cloud, there’s nothing to install, just enable it in your stack. Install the plugin for self-managedAdd one endpoint to a client; complete browser consentInstall and operate a serverInstall the binary and configure contexts
Best forSpecific questions, dashboards, investigations in the UIInteractive diagnosis from your AI client with per-user permissionsSelf-hosted, private networks, service identity, custom policyRepeatable work, CI, GitOps, multi-stack changes
Cost notePer token consumedCounts toward Assistant usage and active usersServer hosting is yours. Grafana usage rules applyFree to use. Grafana usage rules apply.

When to use each tool

See the following scenarios to better understand when to use each tool:

I…UseWhy?
Want an answer, a query, or a dashboard fast from the Grafana UIAssistantNo setup, and Grafana manages context.
Want to allow my LLM to interact with my OSS Grafana instance for common tasksOSS MCPmcp-grafana has a suite of tools for common tasks.
Don’t have an AI subscription, but I want to interact with my self-managed Grafana instance using natural languageGrafana Assistant on-premIt lets you bring the power of Grafana Assistant to your self-hosted Grafana instance.
Have CI pipelines, GitOps, dashboards as code, or work across several stacksgcxExplicit commands, exit codes, and named contexts make changes repeatable and reviewable.
Want conversational diagnosis followed by a reviewed changeMCP for diagnosis, gcx for the changeRefer to Use them together.
Use a coding agent needs flexibility to build its own workflowsgcxgcx is as a broader, less opinionated toolset.

Use the AI tools together

You may use a composite pattern for coding agents: for example, use MCP for conversational discovery and diagnosis, then move durable changes into explicit gcx commands and version-controlled files.

AI tools cycle