DB Explorer MCP server
io.github.AYUSH-148/db-explorer-mcp-server·v0.1.0·7 starsRead-only SQL for PostgreSQL, MySQL and SQLite: schema, safe SELECTs, EXPLAIN, index advice
7 stars146 downloads/wk
Reviews
Write oneNobody has reviewed DB Explorer yet.
If you have run it, two minutes of your experience saves the next person an afternoon.
DB Explorer tools (7, 1 write)
write = sends, deletes, buys or postsRead from the package source without running it. The installed server may list more.
execute_querywrite actionRun one read-only SELECT and return its rows.
explain_queryReturn the database's execution plan for one SELECT, without running it.
explore_schemaList the database's tables and views, or describe one in detail.
migration_contextReturn dialect and one page of table detail for client-side migration drafting.
suggest_indexSuggest indexes for one table or one query.
validate_migrationCheck migration scripts without executing them.
validate_schemaCheck tables for missing primary keys, unindexed foreign keys, very wide tables and tables with no indexes. A page of tables leaves views out.
Public scan report
scanner v0.1.10 · 2026-10-26 · same rubric, same numbers if you re-run it
- Code scan22 source files scanned25/25
- –Live reliabilityno gateway calls yet and no remote to proben/a
- –Tool poisoningtools not inspected (local package is not executed); not countedn/a
- Auth qualitystatic API keys via environment variables6/15
- Maintenancelast push 6 days ago15/15
- Maintainer identityregistry namespace matches repository owner; GitHub account older than a year8/10
How DB Explorer compares
Against every graded Databases MCP server, from our own scans and uptime checks. Updated after each scan run.
- Safety score
- 83/100
- higher than 60% of 802 Databases servers
- Tools
- 7
- the typical Databases server has 8
- Tools that change things
- 14%
- typical: 10%. Fewer write tools means less an agent can break
- GitHub stars
- 7
- more than 76% of 601 Databases servers
- Downloads a week
- 146
- more than 66% of 324 Databases servers with a package
What its tools let an agent do: 6 read · 1 run or deploy
Install DB Explorer in Claude Code, Cursor or VS Code
claude mcp add db-explorer-mcp-server -- uvx db-explorer-mcp-server
What the publisher says
From the DB Explorer repository's README, as published. We do not edit it. Read it on GitHub
DB Explorer MCP
A read-only Model Context Protocol (MCP) server for PostgreSQL, MySQL, and SQLite that lets an AI coding assistant explore, query, and audit a relational database without ever being able to write to it.
<!-- mcp-name: io.github.AYUSH-148/db-explorer-mcp-server -->
Point your MCP client at a database and ask questions in plain language. The client's LLM writes the SQL; this server parses it, refuses anything that is not a single read-only SELECT, executes it with a row cap, and returns structured results. Schema inspection, execution plans, index recommendations, and migration review come along with it.
MCP client LLM -> FastMCP tools -> safety layer -> SQLAlchemy -> database
(writes SQL) (7 tools) (rejects writes) (any dialect)The server makes no LLM API calls of its own, so there is no API key to configure — reasoning happens in whichever client you connect. Works with SQLite, PostgreSQL, and MySQL through SQLAlchemy.
Tested and evaluated. 336 tests run on every push and pull request, plus 26 more against real PostgreSQL and MySQL in CI (Tests). In an agent evaluation, Claude completed 14 of 14 realistic database tasks through these tools with no failed tool calls, an average of 2 calls per task, and a mean independent judge score of 4.6 / 5 (Agent evals).
Why
Giving an assistant raw database credentials means one confused or prompt-injected turn can drop a table. Handing it a read-only replica loses schema context and plan analysis. This server takes the middle path: full introspection and query power, with mutation made structurally impossible at the parser level rather than by asking the model to behave.
Architecture
┌──────────────────────────────────────────────────────────────┐
│ MCP client (Claude Code / Claude Desktop / Inspector) │
│ owns the LLM: reads schema, authors SQL, interprets results │
└───────────────────────────┬──────────────────────────────────┘
│ MCP · stdio (local)
│ · streamable HTTP + bearer token (remote)
┌───────────────────────────▼──────────────────────────────────┐
│ server.py — FastMCP instance + one engine per token group │
│ │
│ explore_schema execute_query explain_query │
│ validate_schema suggest_index migration_context │
│ validate_migration │
└──────┬───────────────────────┬───────────────────┬───────────┘
│ │ │
│ read path │ metadata path │ review path
│ │ │
┌──────▼────────────┐ ┌───────▼─────────┐ ┌──────▼──────────┐
│ safety.py │ │ inspector.py │ │ migration.py │
│ ── trust boundary │ │ schema_health.py│ │ parsesShortened. The full README is on GitHub.
Nothing above is checked by us. What we check is on the safety report.
DB Explorer: common questions
- Is DB Explorer MCP server safe?
- Mostly: it is graded B (83/100). Read the DB Explorer safety report
- How do I install DB Explorer?
- It runs on your machine. Copy the Claude Code, Cursor, VS Code or Claude Desktop config from the install section.
- Does DB Explorer need an API key?
- Yes. The registry entry asks for
DATABASE_URL. - Is DB Explorer maintained?
- The last commit was 13 days ago (2026-10-20). The latest release is v0.1.0.
- What can I use instead of DB Explorer?
- Servers from other publishers that do the same job: DBHub MCP server, Faucet MCP server and PostgreSQL MCP Server. Compare all DB Explorer alternatives.
- How does DB Explorer compare with other Databases MCP servers?
- safety score 83/100 (higher than 60% of 802 Databases servers); tools 7 (the typical Databases server has 8); tools that change things 14% (typical: 10%. Fewer write tools means less an agent can break). Full comparison.
Alternatives to DB Explorer
Same job from other publishers: the closest match first, then the best rated.
- DBHubToken-efficient database MCP server for PostgreSQL, MySQL, MariaDB, SQL Server, Oracle, SQLitenot reviewedWidely usedA
- FaucetSQL database to MCP tools and REST API: PostgreSQL, MySQL, SQL Server, Oracle, SQLite, Snowflake.not reviewedEstablishedA
- PostgreSQL MCP ServerPostgreSQL MCP server - query, schema introspection, explain, and health checks for AI assistantsnot reviewedEstablishedB
Grain SQLRun SQL queries and inspect database schemas through safe, visible MCP tools.not reviewedGrowingB
NeoSQL MCPSchemas, SQL, ERDs, and codegen for PostgreSQL, MySQL, Oracle, SQLite, and more via NeoSQL Desktop.not reviewedGrowingA