LocalFree server, account needed

PostgreSQL MCP server

antonorlov/mcp-postgres-server

Access PostgreSQL databases, including those behind an SSH bastion.

24 GitHub stars10 forks3,900 npm downloads / month

Install PostgreSQL in Claude Code

Claude Code
claude mcp add postgresql -- npx -y mcp-postgres-server
mcp.json (Claude Desktop, Cursor, VS Code, Windsurf)
{
  "mcpServers": {
    "postgresql": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-postgres-server"
      ]
    }
  }
}

Frequently asked questions

What does the PostgreSQL MCP server do?

Access PostgreSQL databases, including those behind an SSH bastion.

Is the PostgreSQL MCP server free?

The server is free, but you will likely need an account. The server itself is free, but it connects to a service that needs an account or API key, which may have paid tiers. Check the provider for current pricing.

Does PostgreSQL run locally or remotely?

Local. Runs on your machine (stdio). You install it with npx, uvx, Docker or from source.

How do I add PostgreSQL to Claude Code?

Run: claude mcp add postgresql -- npx -y mcp-postgres-server

More databases MCP servers

View all