Grafana MCP server (Loki tools)
Grafana Loki does not itself ship an MCP server. The Loki query surface reaches MCP clients through the Grafana Labs MCP servers, which expose Loki as a datasource: the open-source grafana/mcp-grafana server (local stdio / SSE / streamable-http) and the fully hosted Grafana Cloud MCP server at https://mcp.grafana.com/mcp (OAuth 2.1, streamable HTTP only). Both are first-party Grafana Labs software; the Loki tool family below is registered by tools/loki.go in grafana/mcp-grafana.
One-click install for Cursor, VS Code, Claude, and 20+ other MCP clients, powered by API Commons MCP Install — visit install.apicommons.org for more information.
Documentation
Documentation link · transport
Tools
query_loki_logs— Query and retrieve logs using LogQL (either log or metric queries)list_loki_label_names— List all available label names in logslist_loki_label_values— List values for a specific log labelquery_loki_stats— Get statistics about log streamsquery_loki_patterns— Query detected log patterns to identify common structuresanalyze_loki_labels— Audit a Loki label strategy (live or static) and optionally diagnose query performancesuggest_loki_alloy_label_config— Generate an Alloy `loki.process` snippet enforcing approved labels
About MCP
The Model Context Protocol (MCP) is an open protocol Anthropic introduced for connecting LLM-based agents to external tools and data sources. Providers publish MCP servers that expose their API surface as structured, discoverable tools — an MCP-compatible client (Claude Desktop, Cursor, Cline, Continue, etc.) can connect to the server and call its tools without any per-provider integration code.
Browse every MCP server on the APIs.io network or compare with the broader Agent Skill surfaces of the same providers.
Work with this as data
Every MCP server here is available over the APIs.io API and to AI agents over MCP.