What this kind of tool is for
- Query, inspect, or seed a database without writing a one-off script.
- Let your agent look up schema details before it writes migration code.
- Move a small dataset between tools without leaving the terminal.
How to compare servers like this
- Engine match:
- Confirm it speaks your exact database and version, not just the family.
- Access scope:
- Read-only connections are the safe default — start there before granting writes.
- Safety rails:
- Check whether destructive statements need an explicit confirmation before they run.
- Maintenance signal:
- Database drivers change; a recently updated tool is less likely to break mid-query.
This page carries your copy-paste config: pick your MCP client in the install section on this page and use the copy button.
What is the pgops MCP server?
Safe, audited PostgreSQL operations for AI agents: queries, migrations, EXPLAIN, containers
How to install pgops
Copy-paste configuration for popular MCP clients.
PGOPS_DSNrequiredsecretPostgreSQL connection string for the database to operate on.
PGOPS_READONLY_DSNsecretOptional separate DSN for the read-only pool. Use a role with no write grants to enforce read-only at the database rather than only in the server.
PGOPS_READ_ONLYSet to 1 to withhold every mutating tool. Write tools are not registered at all, so an agent cannot call them.
PGOPS_APPROVAL_MODESet to 1 to register container.restart and container.exec. Off by default: Docker socket access is root-equivalent on the host.
PGOPS_AUDIT_LOGPath to the append-only JSONL audit log.
PGOPS_DEFAULT_TIMEOUT_MSStatement timeout applied to every query unless a tool call overrides it.
PGOPS_MAX_TIMEOUT_MSCeiling a caller-supplied timeout is clamped to.
PGOPS_DEFAULT_ROW_LIMITRows returned by query.read when the caller does not specify a limit.
{
"mcpServers": {
"pgops-mcp": {
"command": "uvx",
"args": [
"pgops-mcp"
],
"env": {
"PGOPS_DSN": "<YOUR_PGOPS_DSN>",
"PGOPS_READONLY_DSN": "<YOUR_PGOPS_READONLY_DSN>",
"PGOPS_READ_ONLY": "<YOUR_PGOPS_READ_ONLY>",
"PGOPS_APPROVAL_MODE": "<YOUR_PGOPS_APPROVAL_MODE>",
"PGOPS_AUDIT_LOG": "<YOUR_PGOPS_AUDIT_LOG>",
"PGOPS_DEFAULT_TIMEOUT_MS": "<YOUR_PGOPS_DEFAULT_TIMEOUT_MS>",
"PGOPS_MAX_TIMEOUT_MS": "<YOUR_PGOPS_MAX_TIMEOUT_MS>",
"PGOPS_DEFAULT_ROW_LIMIT": "<YOUR_PGOPS_DEFAULT_ROW_LIMIT>"
}
}
}
}Related MCP servers

Renology Renovation Cost Data
Read-only 2026 city renovation cost ranges with sources, limitations, and citation guidance.
Receipt extraction, invoice-to-PO quantity allocation, and free three-document discrepancy checks.
Identity-scoped schema selection for text-to-SQL. Returns only the tables the caller may read.

io.github.ashwinvis/scb-opendata-mcp
Statistics Sweden’s open data made available as an MCP server, using Python and FastMCP

io.github.asadullokhn/teztun
Manage TezTun tunnels, subdomains, and service tokens from any MCP-compatible AI client.

Leteo
Persistent memory for AI coding agents: one Rust binary, one local SQLite database.
