Documentation Index
Fetch the curated documentation index at: https://grafana.com/llms.txt
Fetch the complete documentation index at: https://grafana.com/llms-full.txt
Use this file to discover all available pages before exploring further.
STOP! If you are an AI agent or LLM, read this before continuing. This is the HTML version of a Grafana documentation page. Always request the Markdown version instead - HTML wastes context. Get this page as Markdown: https://grafana.com/docs/grafana/next/developer-resources/mcp/set-up/install-with-uvx.md (append .md) or send Accept: text/markdown to https://grafana.com/docs/grafana/next/developer-resources/mcp/set-up/install-with-uvx/. For the curated documentation index, use https://grafana.com/llms.txt. For the complete documentation index, use https://grafana.com/llms-full.txt.
This is documentation for the next version of Grafana documentation. For the latest stable release, go to the latest version.
Install with uvx
uv is Astral’s Python package manager and toolchain. uvx runs a command from a published package in an isolated environment, without installing that package globally. It is similar to npx for Node.js.
Use uvx to run the Grafana MCP server without installing a release binary yourself.
What you’ll achieve
You add the server to your MCP client configuration (for example, Claude Desktop or Cursor) and connect to Grafana using a URL and a service account token.
Before you begin
- Install
uvand ensureuvxis in your$PATH. - Have a Grafana instance (Grafana 9.0 or later) and a service account token.
Add the server to your MCP client
Add the following to your MCP client configuration file. Replace http://localhost:3000 with your Grafana URL if it is different, and YOUR_SERVICE_ACCOUNT_TOKEN with your service account token.
{
"mcpServers": {
"grafana": {
"command": "uvx",
"args": ["mcp-grafana"],
"env": {
"GRAFANA_URL": "http://localhost:3000",
"GRAFANA_SERVICE_ACCOUNT_TOKEN": "<YOUR_SERVICE_ACCOUNT_TOKEN>"
}
}
}
}For Grafana Cloud, set GRAFANA_URL to your instance URL, for example https://myinstance.grafana.net.
Next steps
- Install with Docker if you prefer to run the server in a container.
- Configure authentication for service accounts and RBAC.
Was this page helpful?
Related resources from Grafana Labs


