Hosted MCPUtility

Prometheus MCP Server

Query and analyze metrics from a Prometheus server (PromQL, ranges, labels). Useful for observability and SRE workflows from inside an agent.

Setup

1 field

Credentials are injected into an ephemeral sandbox at boot and destroyed with it.

Runtime

Light — starts in seconds

Sessions run up to 60 minutes before the sandbox is reclaimed.

Models

60+ AI models

Chat with 60+ AI models on the same workflow — switch to a different model mid-conversation and re-run the same prompt, or use Compare mode to put several side-by-side.

What the Prometheus MCP server does

How models use it and what it is built for.

The Prometheus MCP server lets a model run PromQL against your metrics — instant queries, range queries over a window, and label exploration to find out what is even being collected.

PromQL is the real barrier here. Most engineers can describe what they want ("p99 latency for the checkout service over the last hour, by pod") and cannot write the query from memory. A model that can both compose PromQL and immediately see whether the result looks sane closes that gap.

It needs only the server URL — no token — because Prometheus itself has no built-in auth. That makes setup trivial and makes network reachability the thing you actually have to think about.

What a model can do with it

Concrete operations exposed as tools.

  • Run instant PromQL queries and return the current value
  • Run range queries across a time window with a step interval
  • List metric names, label names and label values
  • Explore what a job or exporter is actually emitting
  • Compose and iterate on a query until the result is right
  • Correlate several metrics to explain a spike

How to set up the Prometheus MCP server

In order. Each step assumes the previous one worked.

  1. 01

    Expose the server publicly

    The sandbox reaches Prometheus over the public internet. A localhost or private-IP address will not work — use a tunnel (ngrok, Tailscale Funnel) or a reverse proxy with a public hostname.

  2. 02

    Put authentication in front of it

    Prometheus has no native auth, so anything publicly reachable is publicly readable. Front it with basic auth or an IP allowlist at the proxy before you expose it, even briefly.

  3. 03

    Provide the base URL

    The root URL of the server — https://prometheus.example.com — not the /graph or /api/v1 path.

  4. 04

    Verify with a label query

    Ask the model which metric names exist. A real list confirms the URL is right and the server is reachable.

Configuration

What you provide before the sandbox starts.

Prometheus Server URLRequired

e.g. https://prometheus.example.com or http://prom.internal:9090. Must be reachable from the public internet — localhost / private IPs need a tunnel (ngrok / Tailscale Funnel).

Example prompts

Paste any of these into Agent Studio once the server is connected.

What metrics are available for the checkout service? List the label values.

Show me p99 request latency over the last hour, broken down by pod.

Which containers had the highest memory usage in the last 24 hours?

Error rate spiked around 14:00 — query the relevant metrics and explain what happened.

Limits and things to watch

Known constraints, stated plainly.

  • Prometheus has no built-in authentication. Exposing it publicly without a proxy in front makes your metrics world-readable.
  • Private or localhost endpoints are unreachable from the sandbox without a tunnel.
  • Wide range queries with a fine step return very large result sets that get truncated — widen the step instead.
  • Retention is whatever your Prometheus is configured for; this cannot query data that has already been dropped.

Test Prometheus against a real model

Deploy the server hosted, then watch which tools a model actually reaches for — with full JSON input and output on every call. Switch models mid-conversation to compare how each one uses the same server.

Frequently asked questions

About the Prometheus MCP server.

Do I need an API key?

No. Prometheus has no native authentication, so the server needs only a URL. That is exactly why you should put basic auth or an IP allowlist in front of any publicly reachable instance.

My Prometheus is on a private network — can I still use this?

Only through a tunnel. Tailscale Funnel or ngrok will give the sandbox a reachable hostname. There is no way for an ephemeral cloud sandbox to reach a private VPC address directly.

Can the model write or delete metrics?

No. This is a query surface over the read API — there is no ingestion or admin path exposed.

Should I use this or the Grafana MCP server?

Use Prometheus directly when you want raw PromQL and fast iteration on a query. Use Grafana when the context you need is which dashboards and alerts exist, since those live in Grafana rather than in Prometheus.

More