PostgreSQL MCP Server

This repo is an extension of PostgreSQL MCP Server providing functionalities to create tables, insert entries, update entries, delete entries, and

Local serverstdio

What is the PostgreSQL MCP Server?

This repo is an extension of PostgreSQL MCP Server providing functionalities to create tables, insert entries, update entries, delete entries, and drop tables.

The short version

A Model Context Protocol server that provides access to PostgreSQL databases. This server enables LLMs to interact with databases to inspect schemas, execute queries, and perform CRUD (Create, Read, Update, Delete) operations on database entries. This repo is an extension of PostgreSQL MCP Server providing functionalities to create tables, insert entries, update entries, delete entries, and drop tables.

More MCP options

Compare MCP servers by category, or browse hosted MCP servers if you prefer an endpoint over a local process.

How to install the PostgreSQL MCP Server

{
  "mcpServers": {
    "postgres": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "mcp/postgres",
        "postgresql://username:password@host.docker.internal:5432/mydatabase"
      ]
    }
  }
}

Configuration as documented by the project. Restart the client after saving.

Example prompts to try

  • “Use PostgreSQL to Resources.”

Frequently asked questions

It extends the base server with full CRUD capabilities: create tables, insert, update, delete entries, and drop tables, beyond the original read‑only query functionality.