PostgreSQL Performance (read-only)

io.github.gouranshul/pg-perf-mcp

Read-only PostgreSQL performance diagnostics: slow queries, EXPLAIN, index advice, locks, functions

Connect this server

Add this to your MCP client config — claude_desktop_config.json (Claude Desktop) or .cursor/mcp.json (Cursor).Suits: Claude Desktop · Cursor.

{
  "mcpServers": {
    "pg-perf-mcp": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/gouranshul/pg-perf-mcp:0.1.0"
      ],
      "env": {
        "PGPERF_DB_URL": "<your PGPERF_DB_URL>",
        "PGPERF_DB_USER": "<your PGPERF_DB_USER>",
        "PGPERF_DB_PASSWORD": "<your PGPERF_DB_PASSWORD>",
        "MCP_API_KEY": "<your MCP_API_KEY>"
      }
    }
  }
}
Environment variables
  • PGPERF_DB_URLrequiredJDBC URL of the database to diagnose. From inside the container, use host.docker.internal for a database on your machine, e.g. jdbc:postgresql://host.docker.internal:5432/mydb
  • PGPERF_DB_USERrequiredA read-only role with pg_read_all_stats and pg_monitor (see docker/init.sql)
  • PGPERF_DB_PASSWORDrequiredsecretPassword of that role
  • MCP_API_KEYrequiredsecretBearer token clients must send, at least 16 characters (32+ random recommended)

A starting point — check the repository for exact arguments and setup. Restart your client after editing the config.

Category
Developer Tools
Version
0.1.0
Registry
active
Published
10/10/2026
Browse all Developer Tools →

Add the badge to your site

Show visitors that PostgreSQL Performance (read-only) is listed here — it’s also the link we check for a free listing.

PostgreSQL Performance (read-only) — listed on Serverdex

HTML — for your website

<a href="https://serverdex.io/server/io-github-gouranshul-pg-perf-mcp?utm_source=badge"><img src="https://serverdex.io/brand/badge.svg" alt="PostgreSQL Performance (read-only) — listed on Serverdex" width="123" height="40" loading="lazy"></a>

Recommended. A dofollow link from your own domain is the one that counts for search engines, and it's the link we check for a free listing.

Markdown — for your README

[![PostgreSQL Performance (read-only) — listed on Serverdex](https://serverdex.io/brand/badge.svg)](https://serverdex.io/server/io-github-gouranshul-pg-perf-mcp?utm_source=badge)

Nice for visibility, but GitHub marks README links nofollow, so it doesn't pass authority. Use the HTML badge on your site as well.