mcpbeat Sign in

pgleash MCP Server

local only

pgleash runs on your own machine — the client starts it, so there is no endpoint to ping. 532 installs a week from npm. Last commit 30 Nov 2026.

Postgres proxy for AI agents: read-only by default, blocks DROP and unbounded DELETE, caps rows.

Installs per day peak 304 · avg 11
a month agotoday
532
Installs / week
npm · pgleash
1
Stars
0 open issues
30 Nov 2026
Last commit
from GitHub
MIT
License
TypeScript

Connect this server

This server runs on your own machine — install it with the package manager and the client starts it for you. Package name taken from the official registry entry.

run in your terminal
claude mcp add pgleash -e 'PGLEASH_UPSTREAM=<PGLEASH_UPSTREAM>' -- npx -y pgleash mcp
~/Library/Application Support/Claude/claude_desktop_config.json
{
  "mcpServers": {
    "pgleash": {
      "command": "npx",
      "args": [
        "-y",
        "pgleash",
        "mcp"
      ],
      "env": {
        "PGLEASH_UPSTREAM": "<PGLEASH_UPSTREAM>"
      }
    }
  }
}
~/.codex/config.toml
[mcp_servers.pgleash]
command = "npx"
args = ["-y", "pgleash", "mcp"]
env = { PGLEASH_UPSTREAM = "<PGLEASH_UPSTREAM>" }
.cursor/mcp.json
{
  "mcpServers": {
    "pgleash": {
      "command": "npx",
      "args": [
        "-y",
        "pgleash",
        "mcp"
      ],
      "env": {
        "PGLEASH_UPSTREAM": "<PGLEASH_UPSTREAM>"
      }
    }
  }
}
.vscode/mcp.json
{
  "servers": {
    "pgleash": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "pgleash",
        "mcp"
      ],
      "env": {
        "PGLEASH_UPSTREAM": "<PGLEASH_UPSTREAM>"
      }
    }
  }
}

Put your own value in place of <PGLEASH_UPSTREAM> (Connection string of the real database, ideally a least-privilege role). The author’s registry entry marks it as required.

Nothing serious here today

Today is the operative word: we check pgleash every 15 minutes and re-read its code on every release. Watch it and you find out the day that stops being true.

Three servers free · no card

Alternatives to pgleash

same job, measured the same way
Lokra
by lokrahq

Postgres for AI agents with row locks, masking, approved writes and a signed audit ledger.

6 312 installs/wk local only
Notion
by n24q02m

Markdown-first Notion for AI agents -- pages, databases, blocks, and comments in one call.

2 313 installs/wk local only
ROUA: read-only database accounts
by promisegithub

Create and audit read-only database accounts for AI agents: PostgreSQL, MySQL, SQL Server and more.

1 368 installs/wk local only
Sota
by sota

EU-native PaaS for AI agents — deploy web apps with one sentence, managed Postgres, GDPR by default.

1 295 installs/wk 15 tools answering
PostgreSQL CVE & Release Intelligence
by meob

PostgreSQL security for AI agents: CVEs, yanked releases, exploits, and upgrade paths

518 installs/wk local only
Quarry
by yiminspace

Safety-railed database access: Postgres, MySQL, SQLite, Redis. Read-only by default.

453 installs/wk local only
Mcpg
by devopam

Production-grade PostgreSQL MCP server — 279 tools for query, tuning & ops, read-only by default.

421 installs/wk local only
tusk
by volveezz

Postgres for agents: named local/stage/prod targets, READ ONLY reads, opt-in writes, SSH tunnels

311 installs/wk local only

pgleash — questions

Answers built from our own checks of this server.

Why is there no uptime for pgleash?
pgleash runs on your own machine over stdio — there is no network address to reach, so uptime cannot be measured for it by anyone. What can be measured is adoption: the npm package pgleash was installed 532 times last week.
How do I connect pgleash?
Copy the ready config from this page. We generate it for Claude Code, Claude Desktop, Codex, Cursor and VS Code, each in the form that client actually reads. It runs locally, so the command pulls pgleash straight from npm; nothing to host, nothing to sign up for.
How many people use pgleash?
The npm package pgleash was installed 532 times in the last week. We show installs rather than GitHub stars on purpose: a star is a bookmark, an install is someone actually running it.
Is pgleash open source?
Yes — it is published under the MIT licence, written in TypeScript and 1 stars on GitHub. The source link is on this page, so you can read exactly what it does with your data before you connect it.