Prometheus

v1.1.3Monitoring & Observabilitystable

A TypeScript-based MCP server that enables users to interact with Prometheus metrics using PromQL queries and discovery tools. It allows LLMs to retrieve time-series data, metadata, alerts, and system status directly from a Prometheus instance.

mcpprometheusprometheus-mcpprometheus-mcp-servermetrics
Share:
46
Stars
0
Downloads
0
Weekly
0/5

What is Prometheus?

Prometheus is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to typescript-based mcp server that enables users to interact with prometheus metrics using promql queries and discovery tools. it allows llms to retrieve time-series data, metadata, alerts, and system s...

A TypeScript-based MCP server that enables users to interact with Prometheus metrics using PromQL queries and discovery tools. It allows LLMs to retrieve time-series data, metadata, alerts, and system status directly from a Prometheus instance.

This server falls under the Monitoring & Observability category on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • A TypeScript-based MCP server that enables users to interact

Use Cases

Query Prometheus metrics using PromQL from AI agents
Retrieve system status, alerts, and time-series data
mateusdata

Maintainer

LicenseMIT License
Languagego
Versionv1.1.3
UpdatedMay 12, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

NPM

npx -y prometheus

Manual Installation

npx -y prometheus

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use Prometheus

The Prometheus MCP Server enables AI assistants to query and explore Prometheus monitoring systems using natural language, translating questions into PromQL queries and returning time-series data, metric metadata, alert states, recording rules, and scrape target information. DevOps and SRE teams can ask Claude 'show me CPU usage for the web tier over the last hour' or 'are there any firing alerts?' without needing to open the Prometheus UI or remember PromQL syntax. It connects to any Prometheus-compatible endpoint, including Thanos and VictoriaMetrics.

Prerequisites

  • Node.js 18 or later installed
  • npx available (ships with Node.js)
  • A running Prometheus instance accessible from your machine (e.g., http://localhost:9090)
  • An MCP client such as Claude Desktop or the Claude Code CLI
  • Network access from the MCP server host to your Prometheus endpoint
1

Verify your Prometheus instance is reachable

Confirm you can reach the Prometheus API before configuring the MCP server.

curl http://your-prometheus-instance:9090/api/v1/status/config
2

Test the server with npx

Run the server directly with npx to verify it starts correctly. Set PROMETHEUS_HOST to your Prometheus URL.

PROMETHEUS_HOST=http://localhost:9090 npx -y prometheus-mcp-server
3

Configure Claude Desktop

Add the Prometheus MCP server to your Claude Desktop configuration, setting PROMETHEUS_HOST to your Prometheus instance URL.

{
  "mcpServers": {
    "prometheus": {
      "command": "npx",
      "args": ["-y", "prometheus-mcp-server"],
      "env": {
        "PROMETHEUS_HOST": "http://your-prometheus-instance:9090"
      }
    }
  }
}
4

Restart Claude Desktop

Fully quit and relaunch Claude Desktop so it loads the new MCP server configuration.

5

Verify with a test query

Open a new chat in Claude Desktop and ask it to query Prometheus metrics. The server exposes nine tools: instant_query, range_query, get_series, get_label_values, get_metadata, get_targets, get_alerts, get_rules, and get_status.

Prometheus Examples

Client configuration

Claude Desktop configuration for the Prometheus MCP server pointing to a local Prometheus instance.

{
  "mcpServers": {
    "prometheus": {
      "command": "npx",
      "args": ["-y", "prometheus-mcp-server"],
      "env": {
        "PROMETHEUS_HOST": "http://localhost:9090"
      }
    }
  }
}

Prompts to try

Example monitoring questions you can ask Claude with the Prometheus server connected.

- "Query the current CPU usage across all nodes using the node_cpu_seconds_total metric"
- "Show me HTTP request rate over the last 30 minutes for the api-gateway service"
- "Are there any currently firing Prometheus alerts?"
- "List all active scrape targets and their health status"
- "Get the range query for memory usage (node_memory_MemAvailable_bytes) over the last 6 hours with 5-minute resolution"

Troubleshooting Prometheus

Connection refused or ECONNREFUSED when querying metrics

Verify that PROMETHEUS_HOST is set to the correct URL including protocol and port (e.g., http://localhost:9090). Test the endpoint with curl from the same machine where the MCP server runs.

Empty results from instant_query or range_query

Check that the metric name exists by using get_metadata or get_series first. Prometheus metric names are case-sensitive and must match exactly. Also verify the time range covers a period when data was being collected.

npx takes too long to start or times out

Pre-install the package globally to avoid download delays: 'npm install -g prometheus-mcp-server'. Then update the command in your config from 'npx' with args '['-y', 'prometheus-mcp-server']' to just 'prometheus-mcp-server' with empty args.

Frequently Asked Questions about Prometheus

What is Prometheus?

Prometheus is a Model Context Protocol (MCP) server that typescript-based mcp server that enables users to interact with prometheus metrics using promql queries and discovery tools. it allows llms to retrieve time-series data, metadata, alerts, and system status directly from a prometheus instance. It connects AI assistants to external tools and data sources through a standardized interface.

How do I install Prometheus?

Install via npm with the command: npx -y prometheus. Then add the server configuration to your AI client's JSON config file (e.g., claude_desktop_config.json or .cursor/mcp.json).

Which AI clients work with Prometheus?

Prometheus works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is Prometheus free to use?

Yes, Prometheus is open source and available under the MIT License license. You can use it freely in both personal and commercial projects.

Browse More Monitoring & Observability MCP Servers

Explore all monitoring & observability servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "prometheus": { "command": "npx", "args": ["-y", "prometheus"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use Prometheus?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides