L'Atlas / MCP servers / PostgreSQL
MCP server

PostgreSQL

io.github.antonorlov/mcp-postgres-server

MCP server Not tested

Get a review See pricing

MCP server for PostgreSQL: local, Docker, RDS, Neon, Supabase, or behind an SSH bastion.

Technical sheet

Author
antonorlov (registry namespace)
Repository
github.com/antonorlov/mcp-postgres-server
Site
github.com/antonorlov/mcp-postgres-server#readme
Version
0.3.1
Transport
stdio
Authentication
None (declared in the registry)
Packages
mcp-postgres-server 0.3.1 npm stdio
Tools
—
Categories
Databases, Cloud and infrastructure
Last updated
14 Sept 2026
Published
14 Sept 2026

Badge for your README

Listed on L’Atlas

Free, for every entry. It links back to this entry and shows “tested OK” as long as our latest test succeeded. Latest test not successful: the badge only says “listed”.

MarkdownREADME.md
[![Listed on L’Atlas](https://latlas.dev/badge/fiche/io.github.antonorlov/mcp-postgres-server.svg?lang=en)](https://latlas.dev/en/mcp/io.github.antonorlov/mcp-postgres-server)
HTML
<a href="https://latlas.dev/en/mcp/io.github.antonorlov/mcp-postgres-server"><img src="https://latlas.dev/badge/fiche/io.github.antonorlov/mcp-postgres-server.svg?lang=en" alt="Listed on L’Atlas" height="20"></a>

Our tests

No remote address published: this server runs locally, so we do not test it.

Client compatibility

Based on the transports each client documents as supported; this is not a live test inside the client.

ClientDocumented transportsThis serverSource
Claude Codestdio Streamable HTTP SSEtransport accepteddoc
Claude (claude.ai, Claude Desktop, Cowork)stdio Streamable HTTP SSEtransport accepteddoc
ChatGPT (serveurs MCP personnalisés / plugins)Streamable HTTP SSEtransport not listeddoc
Cursorstdio Streamable HTTP SSEtransport accepteddoc
VS Code (GitHub Copilot)stdio Streamable HTTP SSEtransport accepteddoc
Windsurf (documentation redirigée vers Devin Local / Devin CLI)stdio Streamable HTTP SSEtransport accepteddoc
Gemini CLIstdio Streamable HTTP SSEtransport accepteddoc
OpenAI Codex (CLI, extension IDE, app)stdio Streamable HTTPtransport accepteddoc

Ready-to-copy configs

Local launch of package mcp-postgres-server (npm). Formats taken from each client’s documentation.

Claude Code
claude mcp add-json mcp-postgres-server '{"command":"npx","args":["-y","[email protected]"]}'
Claude (claude.ai, Claude Desktop, Cowork)claude_desktop_config.json (macOS : ~/Library/Application Support/Claude/ ; Windows : %APPDATA%\Claude\ ; Linux : ~/.config/Claude/)
{
  "mcpServers": {
    "mcp-postgres-server": {
      "command": "npx",
      "args": ["-y","[email protected]"]
    }
  }
}
Cursor.cursor/mcp.json (projet) ou ~/.cursor/mcp.json (global)
{
  "mcpServers": {
    "mcp-postgres-server": {
      "type": "stdio",
      "command": "npx",
      "args": ["-y","[email protected]"]
    }
  }
}
VS Code (GitHub Copilot).mcp.json à la racine du workspace, ou ~/.copilot/mcp-config.json ($COPILOT_HOME/mcp-config.json)
{
  "mcpServers": {
    "mcp-postgres-server": {
      "type": "stdio",
      "command": "npx",
      "args": ["-y","[email protected]"],
      "tools": ["*"]
    }
  }
}
Windsurf (documentation redirigée vers Devin Local / Devin CLI).devin/mcp_config.json (projet), .devin/mcp_config.local.json (local), ~/.config/devin/mcp_config.json (utilisateur)
{
  "mcpServers": {
    "mcp-postgres-server": {
      "command": "npx",
      "args": ["-y","[email protected]"]
    }
  }
}
Gemini CLI~/.gemini/settings.json (utilisateur) ou .gemini/settings.json (projet)
{
  "mcpServers": {
    "mcp-postgres-server": {
      "command": "npx",
      "args": ["-y","[email protected]"]
    }
  }
}
OpenAI Codex (CLI, extension IDE, app)~/.codex/config.toml (ou .codex/config.toml pour un projet de confiance)
[mcp_servers.mcp-postgres-server]
command = "npx"
args = ["-y","[email protected]"]

Declared environment variables

NameRequiredDescription
DATABASE_URLno (secret)Full connection string (preferred). Supports sslmode in the URL.
PG_HOSTnoDatabase host (fallback when DATABASE_URL is not set).
PG_PORTnoDatabase port.
PG_USERnoDatabase user.
PG_PASSWORDno (secret)Database password.
PG_DATABASEnoDatabase name.
PG_ALLOW_WRITEnoWhen true, execute performs writes and reads are sent directly. Off (default) is read-only: execute refuses writes and each read runs in a READ ONLY transaction.
PG_SSLMODEnoTLS mode. require/allow/prefer encrypt without verifying the certificate; verify-ca/verify-full verify it (supply a CA via PG_SSL_CA). Unlike libpq, allow/prefer do not fall back to plaintext, so a s…
PG_SSL_CAnoPath to a CA certificate file. Setting it by itself implies verify-full.
PG_ENABLE_RUNTIME_CONNECTnoRegister the connect_db tool (runtime credential switching).
PG_MAX_RESULT_BYTESnoByte budget for a query result sent to the model. Whole rows are kept while they fit; over the budget returnedRows < rowCount and truncated is true.
PG_STATEMENT_TIMEOUTnoStatement timeout in milliseconds, applied to every session.
PG_CONNECT_TIMEOUTnoTimeout in milliseconds for a single connect attempt (raise it for slow links or SSH tunnels).
PG_SSH_HOSTnoSSH bastion host. Setting it enables tunneling: the server reaches the database only through an SSH tunnel to this host. Needs the ssh2 optional dependency.
PG_SSH_PORTnoSSH bastion port.
PG_SSH_USERnoSSH username.
PG_SSH_PRIVATE_KEYnoPath to a private key file. If unset, auth falls back like ssh: a running agent (SSH_AUTH_SOCK), then a default key (~/.ssh/id_ed25519, id_rsa, id_ecdsa).
PG_SSH_PASSPHRASEno (secret)Passphrase for the private key, if encrypted.
PG_SSH_AGENTnotrue to use the ambient agent (SSH_AUTH_SOCK), or an explicit socket path / Windows named pipe.
PG_SSH_PASSWORDno (secret)SSH login password. Opt-in; a key or agent takes precedence. Prefer keys, a bastion often disables password auth.
PG_SSH_FINGERPRINTnoPinned host-key fingerprint (SHA256:...). Host-key verification is mandatory and set only this way: without it the tunnel refuses to connect. Get it with ssh-keygen -lF host.
PG_SSH_KEEPALIVE_INTERVALnoSSH keepalive interval in ms; the tunnel drops after 3 unanswered keepalives, and the next call reconnects.

Cite this source

Writing an article or comparison? This entry distinguishes registry information from our measurements. Cite the permanent link and the test date; an OK result is not a security audit or an availability guarantee.

PostgreSQL · L’Atlas

Markdown
[PostgreSQL — L’Atlas](https://latlas.dev/en/mcp/io.github.antonorlov/mcp-postgres-server)
Test methodology and limitations

Source : Registre officiel MCP · retrieved 29 Nov 2026. L’Atlas adds no data beyond this source and its own tests.