Postgres
🗄️ Data & Files
PostgreSQL database assistant with intelligent query execution, schema inspection, health analysis, index tuning recommendations, and query plan optimization.
Tools (7)
Client configuration
Cursor (.cursor/mcp.json)
{
"mcpServers": {
"postgres": {
"command": "uvx",
"args": [
"postgres-mcp@0.3.0",
"--access-mode=restricted"
],
"env": {
"DATABASE_URI": "your-database-uri-here",
"ACCESS_MODE": "your-access-mode-here"
}
}
}
}VS Code (.vscode/mcp.json)
{
"servers": {
"postgres": {
"command": "uvx",
"args": [
"postgres-mcp@0.3.0",
"--access-mode=restricted"
],
"env": {
"DATABASE_URI": "your-database-uri-here",
"ACCESS_MODE": "your-access-mode-here"
},
"type": "stdio"
}
}
}Replace the placeholders before connecting. Authorize in your client when prompted.
The Cursor JSON also works in Claude Desktop's local MCP configuration. Install the required runtime and local software first.