Safedb MCP
by narekmalk
Read-only MCP access to Postgres, MySQL, MariaDB, and SQLite with SQL policies, masking, limits, and audit logs.
Install Safedb MCP
Pick your client, then add it in one click or paste the config.
~/Library/Application Support/Claude/claude_desktop_config.json{
"mcpServers": {
"narekmalk-safedb-mcp": {
"command": "npx",
"args": [
"-y",
"@safedb/safedb-mcp"
],
"env": {
"DATABASE_URL": "YOUR_VALUE_HERE"
}
}
}
}
Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.
Values are written into the snippet above so you can paste it as is. They never leave your browser.
claude mcp add --env DATABASE_URL=YOUR_VALUE_HERE --transport stdio narekmalk-safedb-mcp -- npx -y @safedb/safedb-mcpRun in your terminal. Add --scope project to share it with your team through .mcp.json.
We couldn’t confirm it starts correctly
We ran the install command but it didn't respond within our test window — this can mean a slow first-time install rather than a real problem.
npx -y @safedb/safedb-mcpNo response to initialize.
This is an experimental automated check and can have false negatives — missing environment variables, a slow cold install, etc. It doesn’t necessarily mean something’s wrong. Last checked .
Overview
Use cases
- Inspect approved database schemas and tables
- Run read-only SQL queries against permitted tables
- Mask email, phone, password, or other sensitive columns
- Audit database query attempts made through MCP
- Explain approved SELECT queries before execution
Key features
- MCP tools for schemas, tables, descriptions, queries, explanations, and policy inspection
- Postgres, MySQL, MariaDB, and SQLite support
- AST-backed guardrails for SELECT, CTEs, UNION, and EXPLAIN SELECT
- Configurable schema and table allowlists, denylists, row limits, and timeouts
- PII masking with redact, email, partial, and deterministic hash modes
- JSONL audit logs without raw result data
Security & health
What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.
Recent health check succeeded.
Supply-chain signal
No high-severity advisories surfaced by our automated scan.
Scanned 16d ago via OSV.dev · @safedb/safedb-mcp (npm)
Adoption & maintenance
Factual signals from GitHub, npm, and our automated checks — not a rating.
From the project README
Reviews
No reviews yet — be the first to share how it worked for you.
Frequently Asked Questions about Safedb MCP
Related MCP servers
Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.
AllMCPs Directory Badge
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/narekmalk-safedb-mcp)<a href="https://allmcps.com/mcp/narekmalk-safedb-mcp"><img src="https://allmcps.com/api/badge/narekmalk-safedb-mcp?style=directory" alt="Safedb MCP on AllMCPs" /></a>