Skip to main content
AllMCPs
BrowseBestCategoriesStackCompareToolsGuidesBlog
Log in Submit MCP

Stay in the loop

Get new MCP servers and top picks in your inbox.

AllMCPs

The open directory for discovering and installing Model Context Protocol servers.

AllMCPs on GitHub (opens in a new tab)
Launched onTiny Startupstinystartups.com
Explore
  • Browse servers
  • Best MCP servers
  • Categories
  • MCP clients
  • Agent prompts
  • Stack Builder
  • Compare servers
  • Random discovery New
  • Submit a server
  • Pricing & Boost Boost
Learn
  • Guides hub
  • What is MCP?
  • Install guide
  • Build an MCP server
  • Deploy an MCP server
  • Security guide
  • Troubleshooting
  • MCP for SEO & AEO
  • Protocol versioning
  • Blog & updates
Tools
  • All developer tools
  • Config generator
  • Config validator
  • Config auditor
  • MCP playground
  • Token calculator
  • OpenAPI โ†’ MCP
  • Badge generator
For agents
  • REST API docs
  • Trust & traffic Live
  • Remote MCP server SSE โ†— (opens in a new tab)
  • llms.txt โ†— (opens in a new tab)
  • Catalog JSON โ†— (opens in a new tab)
Company
  • About
  • Advertise Sponsor
  • Contact
  • GitHub โ†— (opens in a new tab)
  • Terms
  • Privacy
AllMCPs VerifiedAllMCPs VerifiedFeatured on Nick LaunchesFeatured on Nick LaunchesLaunch Llama NewsletterLaunch Llama NewsletterVerified DR - allmcps.comVerified DR - allmcps.comFeatured on SaaSGrowFeatured on SaaSGrowFeatured on Twelve ToolsFeatured on Twelve ToolsFeatured on Saaspa.geFeatured on Saaspa.geFeatured on Findly.toolsFeatured on Findly.toolsFeatured on Startup FameFeatured on Startup FameFeatured on LaunchKiwiFeatured on LaunchKiwiFeatured on ScrollLaunchFeatured on ScrollLaunchFeatured on DailyPingsFeatured on DailyPingsFazier badgeFazier badgeFeatured on NewTool.siteFeatured on NewTool.siteFeatured on saasfame.comFeatured on saasfame.comDR Checker - Domain RatingDR Checker - Domain RatingListed on Turbo0Listed on Turbo0Launched on LaunchBoard - Product Launch PlatformLaunched on LaunchBoard - Product Launch PlatformList on SimilarlabsList on Similarlabshttps://codetrendy.comhttps://codetrendy.comListed on DevTool.ioFeatured on BuildlistFeatured on BuildlistLaunched on Tiny StartupsFeatured on ShowMeBestAIFeatured on ShowMeBestAIFind us on LaunchZoneFind us on LaunchZoneAllMCPs VerifiedAllMCPs VerifiedFeatured on Nick LaunchesFeatured on Nick LaunchesLaunch Llama NewsletterLaunch Llama NewsletterVerified DR - allmcps.comVerified DR - allmcps.comFeatured on SaaSGrowFeatured on SaaSGrowFeatured on Twelve ToolsFeatured on Twelve ToolsFeatured on Saaspa.geFeatured on Saaspa.geFeatured on Findly.toolsFeatured on Findly.toolsFeatured on Startup FameFeatured on Startup FameFeatured on LaunchKiwiFeatured on LaunchKiwiFeatured on ScrollLaunchFeatured on ScrollLaunchFeatured on DailyPingsFeatured on DailyPingsFazier badgeFazier badgeFeatured on NewTool.siteFeatured on NewTool.siteFeatured on saasfame.comFeatured on saasfame.comDR Checker - Domain RatingDR Checker - Domain RatingListed on Turbo0Listed on Turbo0Launched on LaunchBoard - Product Launch PlatformLaunched on LaunchBoard - Product Launch PlatformList on SimilarlabsList on Similarlabshttps://codetrendy.comhttps://codetrendy.comListed on DevTool.ioFeatured on BuildlistFeatured on BuildlistLaunched on Tiny StartupsFeatured on ShowMeBestAIFeatured on ShowMeBestAIFind us on LaunchZoneFind us on LaunchZone
ยฉ 2026 Jackalope Digital LLC. All rights reserved.
  1. Home
  2. ๐Ÿ—„๏ธ Databases
  3. Pgmcp
Pgmcp logo
Health: ActiveRecent health check succeeded.Last checked 9/11/2026, 3:16:21 PM

Pgmcp

User RatingsBe the first to rate and review this MCP server!
View Repository540 GitHub StarsTotal stargazers on GitHub for the source repository (540 stars).Visit Website
postgresqldatabasesqlmcp

Connects MCP clients to PostgreSQL for natural-language, read-only SQL, text search, and streamed results.

Quick Install

Automated & IDE Setup

Copy the AI prompt to install this server into Claude Code, Cursor, or another agent โ€” or use 1-click editor setup below.

Add to CursorAdd to VS Code
Manual Client & Custom JSON ConfigExpand JSON โ–พ

Client Config & Setup

Remote HTTP
Choose your client or environment
Target File:~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "subnetmarco-pgmcp": {
      "url": "http://localhost:8080/mcp"
    }
  }
}

๐Ÿ’ก Paste the JSON block into your client's configuration file under mcpServers, then restart the application.

Install Directory Badge Claim listing Alternatives๐Ÿ—„๏ธ More in Databases

Overview

The subnetmarco/pgmcp MCP server connects MCP-compatible clients to an existing PostgreSQL database through natural-language questions. It can generate SQL with OpenAI, enforce read-only access, stream large result sets, search text columns, and return table, JSON, or CSV output. The server exposes HTTP MCP access at a configurable endpoint and can run with precompiled binaries, Docker, or from source. Reach for it when an AI assistant needs to inspect or query PostgreSQL data without modifying the database schema.

Use cases

โ€ขAsk natural-language questions about PostgreSQL data
โ€ขSearch text columns across an existing database
โ€ขStream large query results with pagination
โ€ขInspect database contents from Cursor or Claude Desktop

Key features

โ€ขNatural-language to SQL generation
โ€ขRead-only SQL enforcement
โ€ขAutomatic result streaming and pagination
โ€ขFree-text search across text columns
โ€ขTable, JSON, and CSV output
โ€ขMixed-case PostgreSQL table support

Capabilities & Tool Schemas

Inspect callable tools, capabilities, and parameters exposed to AI agents by Pgmcp.

Extracted Tool Capabilities
Natural-language to SQL generation
Read-only SQL enforcement
Automatic result streaming and pagination
Free-text search across text columns
Table, JSON, and CSV output
Mixed-case PostgreSQL table support

How Pgmcp works

What subnetmarco/pgmcp MCP server does

The subnetmarco/pgmcp MCP server gives AI assistants access to an existing PostgreSQL database through MCP. Users can ask questions such as which customers placed the most orders or how many orders were created on a given day. The server translates natural-language requests into SQL and returns structured results.

It is intended to work with arbitrary PostgreSQL schemas rather than a bundled application schema. No database schema changes are required. The project also includes example schemas for testing, including one with mixed-case table names and another with composite primary keys.

How it works

An MCP client connects to the server over streamable HTTP. The server connects to PostgreSQL using the DATABASE_URL connection string, inspects the available database structure, and processes requests through its MCP tools. OpenAI can be enabled for SQL generation, with gpt-4o-mini used by default when no model is specified.

The subnetmarco/pgmcp MCP server applies read-only safeguards before executing generated SQL. It also supports query timeouts, connection pooling, automatic pagination, and streaming for larger result sets. When generated SQL is invalid, the server reports the database error and a suggestion rather than terminating the service.

Results can be formatted as tables, JSON, or CSV. The separate command-line client supports asking questions, issuing text searches, sending multiple questions, and limiting the number of returned rows.

Setup and configuration

A PostgreSQL database and the DATABASE_URL environment variable are required. The server can be obtained as a platform-specific release binary, built with Go, or run using the published Docker image. The repository also documents Kubernetes manifests and a Homebrew option described as available after the first release.

The subnetmarco/pgmcp MCP server accepts these configuration variables:

  • DATABASE_URL: PostgreSQL connection string; required.
  • OPENAI_API_KEY: optional key for AI-assisted SQL generation.
  • OPENAI_MODEL: optional model name; defaults to gpt-4o-mini.
  • HTTP_ADDR: listening address; defaults to :8080.
  • HTTP_PATH: MCP endpoint path; defaults to /mcp.
  • AUTH_BEARER: optional bearer token for authentication.

Cursor and Claude Desktop can connect to a local instance at http://localhost:8080/mcp when the default address and path are used.

Tools and capabilities

The exposed MCP tools are:

  • ask: converts a natural-language question into a SQL query and streams the result when needed.
  • search: searches across text columns in the database.
  • stream: provides advanced streaming and pagination for very large result sets.

The implementation handles PostgreSQL mixed-case table names and supports multiple output formats. Its write protections block operations such as INSERT, UPDATE, and DELETE, making it suited to read-oriented analytics and database exploration.

Limitations and notes

The database must be PostgreSQL; the stated compatibility covers PostgreSQL databases and their varying schemas, not arbitrary database engines. AI-powered SQL generation uses OpenAI only when an API key is supplied, so users should account for that external dependency when enabling the feature. Natural-language results still depend on the generated SQL matching the database schema; invalid queries produce an error and guidance to rephrase the request.

The project documentation describes HTTP MCP configuration rather than a direct desktop stdio configuration. Running the service also requires access to the target database and a suitable PostgreSQL connection string.

Read the full README โ†’View source on GitHub โ†’

Related MCP Servers

View all in Databases View all alternatives
  • MCP Server Mysql logoMCP Server Mysql

    MySQL database integration in NodeJS with configurable access controls and schema inspection

    ๐Ÿ—„๏ธ Databases3 views
    Compare vs MCP Server Mysql โ†’
  • MCP Server Duckdb logoMCP Server Duckdb

    DuckDB database integration with schema inspection and query capabilities

    ๐Ÿ—„๏ธ Databases2 views
    Compare vs MCP Server Duckdb โ†’
  • Supabase MCP Server logoSupabase MCP Server

    Supabase MCP Server with support for SQL query execution and database exploration tools

    ๐Ÿ—„๏ธ Databases5 views
    Compare vs Supabase MCP Server โ†’
  • Genai Toolbox logoGenai Toolbox

    Open source MCP server specializing in easy, fast, and secure tools for Databases.

    ๐Ÿ—„๏ธ Databases5 views
    Compare vs Genai Toolbox โ†’

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks โ€” not a rating.

GitHub stars
540
Stargazers on the source repository.
Last commit
3mo ago
Most recent push to the default branch.
Directory activity
3 views
Config copies, upvotes, and views on AllMCPs.

Reviews

No reviews yet โ€” be the first to share how this listing worked for you.

Frequently Asked Questions about Pgmcp

Download a platform-specific binary from the GitHub Releases page, build the server with Go, or use the documented Docker image. Set DATABASE_URL before starting it.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewPgmcp AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/subnetmarco-pgmcp?style=directory)](https://allmcps.com/mcp/subnetmarco-pgmcp)
HTML Embed
<a href="https://allmcps.com/mcp/subnetmarco-pgmcp"><img src="https://allmcps.com/api/badge/subnetmarco-pgmcp?style=directory" alt="Pgmcp on AllMCPs" /></a>

Technical Specs & Signals

Category๐Ÿ—„๏ธDatabases
PricingFree
More technical detailsExpand โ–พ
TransportSSE (Remote)
AuthAPI key
LicenseApache-2.0
ClientsClaude Desktop, Cursor
Last updatedSep 7, 2026
5/6 checks healthy over the last 32d
Views3
Unique ViewsTotal visits recorded for this listing page on AllMCPs.
Installs0
Installs & Copy ActionsTotal times users copied install commands or configuration snippets for this server.
GitHub stars540
GitHub Star CountTotal stargazers on GitHub representing community popularity (540 stars).
Last commit3mo ago
Last Repository CommitThe most recent commit or push recorded for this server's GitHub repository.Last commit on May 26, 2026
45Quality signal: Fair ยท 45/100How this signal is calculated โ–พ
Server availabilityNot measured

Not scored for repo-hosted servers โ€” we can't reach the running server, only its GitHub page. Hosted MCP endpoints are health-checked live.

Verified ownership10/20
Documentation & tools18/30
Adoption & activity6/15
Community engagement0/10

A guidance signal from public completeness & health data โ€” not a user rating. New listings start lower and rise as they add docs, get verified, and grow adoption. Signals we can't observe for a listing are skipped, not counted against it.

โ˜… FeaturedMoxie Docs MCP logo

Moxie Docs MCP

MCP & Agent Skills for Automated Documentation, and codebase conventions + context

Explore Server โ†’

Own this project?

This directory is pre-filled from public sources. Claim via GitHub README, site badge, or DNS TXT to unlock edit access and the Official badge โ€” proof is checked automatically, then reviewed by our team.

Free dofollow backlink: add your website and place the AllMCPs badge on it โ€” no claim needed. We detect it automatically and keep it verified as long as the badge stays live.

Claim & get free dofollow

Share & Embed

Add our SVG badge (dark/light directory styles) or embeddable widget to your site.

Explore more

More in ๐Ÿ—„๏ธ Databases โ†’Best MCP servers for Databases โ†’Alternatives to Pgmcp โ†’Install in Claude DesktopInstall in CursorInstall in VS Code