PostgreSQL MCP Server
PostgreSQL MCP Server connects MCP clients to PostgreSQL for schema inspection and query workflows.
Key Features
- Inspect schemas, tables, columns, and indexes.
- Run read-oriented SQL during analysis and debugging.
- Pair database context with coding agents.
Server Configuration
{
"mcpServers": {
"postgres": {
"command": "npx",
"args": ["@modelcontextprotocol/server-postgres", "postgres://user:pass@localhost:5432/db"]
}
}
}
Security Notes
Use least-privilege database credentials and avoid production write permissions unless explicitly required.