PostgreSQL MCP Server
About
This repo is an extension of PostgreSQL MCP Server providing functionalities to create tables, insert entries, update entries, delete entries, and drop tables.
Details
- License
- MIT
Explore
- Execute read-only SQL queries via the query tool.
- Create tables dynamically with specified columns and data types.
- Insert new entries into any table.
- Update existing entries based on conditions.
- Delete entries from tables using conditions.
- Drop entire tables from the database.
- Provides JSON schema information for each table as a resource.
Setting up with Highlight
This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:
- Download and install Highlight from highlightai.com/download
- Navigate to the plugins tab and select "Add Custom Plugin"
-
Configure the plugin with the settings below
Plugin Name
PostgreSQL MCP ServerCommand (node, npx, python, etc.)Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.
- Enable "Start Automatically" if you want the plugin to start when Highlight launches
From the repository
To install the PostgreSQL MCP Server, follow these steps:
1. Install Docker and Claude Desktop
2. Clone the repository: git clone https://github.com/vignesh-codes/ai-agents-mcp-pg.git
3. Run PG Docker container docker run --name postgres-container -e POSTGRES_USER=admin -e POSTGRES_PASSWORD=admin_password -e POSTGRES_DB=mydatabase -p 5432:5432 -d postgres:latest
4. Build the mcp server: docker build -t mcp/postgres -f src/Dockerfile .
5. Open Claude Desktop and connect to the MCP server by updating the mcpServers field in claude_desktop_config.json:
To use this server with the Claude Desktop app, add the following configuration to the "mcpServers" section of your claude_desktop_config.json:
Claude Desktop / Cursor
Paste into your MCP client config file to install this server.
{
"mcpServers": {
"postgresql mcp server": {
"postgres": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"mcp/postgres",
"postgresql://username:[email protected]:5432/mydatabase"
]
}
}
}
}
McpServers
{
"postgres": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"mcp/postgres",
"postgresql://username:[email protected]:5432/mydatabase"
]
}
}
Sign in to leave a review
Use Google, GitHub, or an email account so ratings stay tied to real people.
No reviews posted yet.



