DBHub (Bytebase)
Token-conscious universal database MCP server for Postgres, MySQL, SQLite, SQL Server, Oracle, and MariaDB.
About this Server
DBHub by Bytebase is a token-conscious Model Context Protocol (MCP) server that consolidates database access for AI coding assistants. Supporting PostgreSQL, MySQL, SQLite, SQL Server, Oracle, and MariaDB, DBHub provides schema exploration, safe query execution with transactions, EXPLAIN query planning, and connection health diagnostics while preserving LLM context windows through progressive schema disclosure.
Direct low-latency RPC protocol communication with structured JSON schemas.
Restricted capability bounds to prevent accidental modifications or leakage.
Security & Best Practices
When to Use (and When Not To)
- •Local schema exploration, SQL query generation, and query debugging across multi-database environments
- •Diagnosing slow query plans with EXPLAIN before pushing changes to production
- •Consolidating multiple database MCP servers (Postgres, MySQL, SQLite, Oracle) into a single unified process
- •Vector embedding similarity search across high-dimensional vectors (use Chroma MCP instead)
- •Document and website web scraping (use Firecrawl MCP instead)
- •Public package and SDK documentation lookups (use Context7 MCP instead)
Install & Setup
claude mcp add dbhub -- npx -y @bytebase/dbhub@latest --transport stdio --dsn "$DATABASE_URL"Exposed Tools & Endpoints
4 toolsFunctions your AI agent can invoke via this Model Context Protocol server
Executes SQL queries with transaction rollback support, row limits, and runaway query safety controls.
Explores database schemas, tables, columns, indexes, and procedures using progressive disclosure to save tokens.
Generates query execution plans without running the query to analyze index usage and query cost.
Reports database connection pool status, active connections, and buffer cache hit ratio.