LABSCO SUMMARY
Minimal by design, and the mode is a launch argument.
There is no per-tool permission model: whichever mode the process started in applies to every query, so a read-only connection and a write connection are two separate client entries. The connection string carries the credentials, which means the database role you point it at is the real limit on what any query can do.
What it is
A minimal server that executes SQL queries against a PostgreSQL database, with the permission level fixed by a command-line argument when the process starts.
What you get
- SQL executed against the database in the connection string you supply
- A server-level mode set on the command line —
readonlyorwrite - Structured results with metadata rather than raw rows
- One connection string as the entire configuration
Requirements
Node. Clone, npm install, npm run build, then point your client at build/index.js with two arguments: the PostgreSQL connection string — for example postgresql://username:password@localhost:5432/database_name — and the mode. Write mode is the default when the second argument is omitted.
Setup effort
Build from source — git clone https://github.com/perrypixel/Simple-Postgres-MCP
USE CASES
Asking a question of a production database safely
Register it in readonly mode so every query that would change data is refused.
Working on a development database
Register a second entry in write mode against the dev connection string, and keep the two apart.
Getting an answer without opening a SQL client
Ask in the conversation; the results come back structured, with the metadata around them.
Restricting by database role rather than by tool
Point the connection string at a role that only has the grants you are willing to expose.
BEFORE YOU INSTALL
What to know first
Requires
- Node.js and npm
- A PostgreSQL database you can reach, and its connection string (postgresql://username:password@host:5432/database_name)
Where it runs
All 3 documented clients run the server on your machine.
INSTALLATION
Connect your client
You clone and build this one yourself.
Server setup
git clone https://github.com/perrypixel/Simple-Postgres-MCP
cd Simple-Postgres-MCP
npm install
npm run buildMCP Clients
Cursor, Windsurf, GitHub Copilot
{
"mcpServers": {
"simple-postgresql-mcp": {
"command": "node",
"args": [
"<YOUR_PATH_TO_BUILD>/index.js",
"postgresql://<YOUR_DB_USER>:<YOUR_DB_PASSWORD>@localhost:5432/<YOUR_DB_NAME>",
"write"
]
}
}
}