Database MCP server for MySQL, MariaDB, PostgreSQL & SQLite
Config is the same across clients — only the file and path differ.
{
"mcpServers": {
"ai-haymon-dbmcp": {
"command": "<see-readme>",
"args": []
}
}
}Are you the author?
Add this badge to your README to show your security score and help users find safe servers.
Database MCP server for MySQL, MariaDB, PostgreSQL & SQLite
No automated test available for this server. Check the GitHub README for setup instructions.
Five weighted categories — click any category to see the underlying evidence.
No known CVEs.
No package registry to scan.
This server is missing a description. Tools and install config are also missing.If you've used it, help the community.
Add informationBe the first to review
Have you used this server?
Share your experience — it helps other developers decide.
Sign in to write a review.
Others in data
Manage Supabase projects — databases, auth, storage, and edge functions
Query and manage PostgreSQL databases directly from AI assistants
MCPSDK.dev(ToolSDK.ai)'s Awesome MCP Servers and Packages Registry and Database with Structured JSON configurations. Supports OAuth2.1, DCR...
An MCP server that securely interfaces with your iMessage database via the Model Context Protocol (MCP), allowing LLMs to query and analyze iMessage conversations. It includes robust phone number validation, attachment processing, contact management, group chat handling, and full support for sending and receiving messages.
MCP Security Weekly
Get CVE alerts and security updates for ai.haymon/dbmcp and similar servers.
Start a conversation
Ask a question, share a tip, or report an issue.
Sign in to join the discussion.
A single-binary MCP server for SQL databases. Connect your AI assistant to MySQL/MariaDB, PostgreSQL, or SQLite with zero runtime dependencies.
Website · Documentation · Releases

listDatabases, listTables, getTableSchema, readQuery, writeQuery, createDatabase, dropDatabase, dropTable, explainQuerymacOS, Linux, WSL:
curl -fsSL https://dbmcp.haymon.ai/install.sh | bash
Windows PowerShell:
irm https://dbmcp.haymon.ai/install.ps1 | iex
Windows CMD:
curl -fsSL https://dbmcp.haymon.ai/install.cmd -o install.cmd && install.cmd && del install.cmd
See the installation docs for Docker, Cargo, and other methods.
.mcp.json (recommended)Add a .mcp.json file to your project root. MCP clients read this file and configure the server automatically.
Stdio transport — the client starts and manages the server process:
{
"mcpServers": {
"dbmcp": {
"command": "dbmcp",
"args": ["stdio"],
"env": {
"DB_BACKEND": "mysql",
"DB_HOST": "127.0.0.1",
"DB_PORT": "3306",
"DB_USER": "root",
"DB_PASSWORD": "secret",
"DB_NAME": "mydb"
}
}
}
}
HTTP transport — you start the server yourself, the client connects to it:
# Start the server first
dbmcp http --db-backend mysql --db-user root --db-name mydb --port 9001
{
"mcpServers": {
"dbmcp": {
"type": "http",
"url": "http://127.0.0.1:9001/mcp"
}
}
}
Note: The
"type": "http"field is required for HTTP transport. Without it, clients like Claude Code will reject the config.
# MySQL/MariaDB
dbmcp stdio --db-backend mysql --db-host localhost --db-user root --db-name mydb
# PostgreSQL
dbmcp stdio --db-backend postgres --db-host localhost --db-user postgres --db-name mydb
# SQLite
dbmcp stdio --db-backend sqlite --db-name ./data.db
# HTTP transport
dbmcp http --db-backend mysql --db-user root --db-name mydb --host 0.0.0.0 --port 9001
DB_BACKEND=mysql DB_USER=root DB_NAME=mydb dbmcp stdio
Configuration is loaded with clear precedence:
CLI flags > environment variables > defaults
Environment variables are typically set by your MCP client (via env or envFile in the server config).
| Subcommand | Description |
|---|---|
stdio | Run in stdio mode |
http | Run in HTTP/SSE mode |
version | Print version information and exit |
A subcommand is required — running dbmcp with no subcommand prints usage help and exits with a non-zero status.
| Flag | Env Variable | Default | Description |
|---|---|---|---|
--db-backend |