1. Conduid
  2. Developer Tools
  3. DBHub
MCP server · Developer Tools

DBHub

Token conscious database MCP server for Postgres, MySQL, SQL Server, Oracle, MariaDB, SQLite.

97Excellent

Scored 11 hours ago · breakdown

About DBHub

DBHub is an MCP server published by bytebase in the Developer Tools category: token conscious database MCP server for Postgres, MySQL, SQL Server, Oracle, MariaDB, SQLite.

The repository has 3.7K stars and 336 forks, with the last commit 5 days ago. Recent commit activity is the strongest signal that reported issues will get attention.

Install

From source
git clone https://github.com/bytebase/dbhub

This server has no ConduID identity, so agent calls to it are not receipted. Pin the version you install and review the source before granting it credentials.

Ask AI

✦

Ask AI about DBHub

Powered by Claude · Grounded in docs

I know everything about DBHub. Ask me about installation, configuration, usage, or troubleshooting.

Security checks

Static checks derived from the repository yesterday. Heuristics on the source, not an audit.

  • ✓README presentThe repository ships documentation.
  • ✓License declaredUsable under a stated license.
  • ✓Tests presentA test suite exists in the repository.
  • ✓Dependencies pinnedA lockfile pins dependency versions.
  • ✓No dynamic code executionSource scan found no eval, dynamic Function, or shell execution.
  • !Scoped permissionsDoesn't declare a permission scope. Assume it can do anything its process can.

Releases

v1.5.0v1.5.0 · 9 Oct 2026What's Changed docs: point CLAUDE.md at src/connectors/interface.ts by @roli-lpci in https://github.com/bytebase/dbhub/pull/447 fix(config): reject empty TOML sslmode before DSN fallback by @tsiakoulias in…
v1.4.0v1.4.0 · 28 Sep 2026What's Changed Add glama.json to enable claiming the Glama listing by @adela-bytebase in https://github.com/bytebase/dbhub/pull/440 Support sslcert/sslkey client certificate authentication for PostgreSQL by @tianzhou in…
v1.3.1v1.3.1 · 21 Sep 2026What's Changed fix: reload AWS credentials from disk on every RDS IAM token refresh by @tianzhou in https://github.com/bytebase/dbhub/pull/438 Full Changelog: https://github.com/bytebase/dbhub/compare/v1.3.0...v1.3.1
v1.3.0v1.3.0 · 19 Sep 2026What's Changed feat(postgres): support per-source pool size by @cendaifeng in https://github.com/bytebase/dbhub/pull/427 fix: apply max_rows to comment-prefixed and CTE queries by @tianzhou in https://github.com/bytebase/dbhub/pull/429…
v1.2.5v1.2.5 · 15 Sep 2026What's Changed Fix: make a failed AWS IAM refresh recoverable instead of losing the source by @tianzhou in https://github.com/bytebase/dbhub/pull/425 Full Changelog: https://github.com/bytebase/dbhub/compare/v1.2.4...v1.2.5

README

[!NOTE]
If you need an enterprise-level database MCP server with built-in guardrails like approval flow, access control, data masking, and audit logging beyond what DBHub offers, check out Bytebase.

            +------------------+    +--------------+    +------------------+
            |                  |    |              |    |                  |
            |  Claude Desktop  +--->+              +--->+    PostgreSQL    |
            |                  |    |              |    |                  |
            |  Claude Code     +--->+              +--->+    SQL Server    |
            |                  |    |              |    |                  |
            |  Cursor          +--->+    DBHub     +--->+    Oracle        |
            |                  |    |              |    |                  |
            |  VS Code         +--->+              +--->+    SQLite        |
            |                  |    |              |    |                  |
            |  Copilot CLI     +--->+              +--->+    MySQL         |
            |                  |    |              |    |                  |
            |                  |    |              +--->+    MariaDB       |
            |                  |    |              |    |                  |
            +------------------+    +--------------+    +------------------+
                 MCP Clients           MCP Server             Databases

DBHub is a minimal MCP server: token-efficient, zero-dependency, and just two tools by default with opt-in extras. This lightweight gateway allows MCP-compatible clients to connect to and explore different databases:

  • Minimal: Zero dependency, token efficient with a minimal set of MCP tools to maximize context window
  • Multi-Database: PostgreSQL, MySQL, MariaDB, SQL Server, Oracle, and SQLite through a single interface
  • Multi-Connection: Connect to multiple databases simultaneously with TOML configuration
  • Guardrails: Read-only mode, row limiting, and query timeout to prevent runaway operations
  • Secure Access: SSH tunneling and SSL/TLS encryption

DBHub is the official example in the Claude Code docs for connecting to PostgreSQL via MCP.

Token Efficiency

DBHub loads just 2 tools by default at 1.4k tokens — 13-14x fewer than alternatives — keeping the context window open for your actual work.

MCP Server Default Config Default Tools
DBHub 1.4k 2 (execute_sql, search_objects)
MCP Toolbox 19.0k 28
Supabase MCP 19.3k all

Use Cases

  • Local Development: Schema exploration, query validation, and data debugging with Claude Code, VS Code, Cursor, etc.
  • Non-Technical Access: Expose curated, read-only views to non-technical staff via Claude Desktop, VS Code, Cursor, etc.
  • Multi-Database Consolidation: Replace separate MCP servers for each database with a single DBHub process
  • Production Troubleshooting: Read-only diagnostics with guardrails against runaway queries

Supported Databases

PostgreSQL, MySQL, SQL Server, MariaDB, Oracle, and SQLite.

MCP Tools

DBHub implements MCP tools for database operations:

  • execute_sql: Execute SQL queries with transaction support and safety controls
  • search_objects: Search and explore database schemas, tables, columns, indexes, and procedures with progressive disclosure
  • explain_sql (opt-in): Show a query's execution plan without running it
  • health_check (opt-in): Report connection pool state and buffer cache hit ratio
  • Custom Tools: Define reusable, parameterized SQL operations in your dbhub.toml configuration file

Workbench

DBHub includes a built-in web interface for interacting with your database tools. It provides a visual way to execute queries, run custom tools, and view request traces without requiring an MCP client.

workbench

Installation

npx @bytebase/dbhub@latest --transport http --port 8080 --dsn "postgres://user:password@localhost:5432/dbname?sslmode=disable"

Also available as:

See the Installation Guide for all options, Command-Line Options for parameters, and Multi-Database Configuration for connecting several databases at once.

Development

Requires Node.js >= 22.5.0 (DBHub uses the built-in node:sqlite module).

# Install dependencies
pnpm install

# Run in development mode
pnpm dev

# Build and run for production
pnpm build && pnpm start --transport stdio --dsn "postgres://user:password@localhost:5432/dbname"

See Testing and Debug.

Contributors

Star History

README fetched from the repository yesterday. The original is authoritative.

Questions

About DBHub

How do I install DBHub?

No package has been published for this server, so install it from source: clone the repository and follow its README.

Is DBHub safe to use with an AI agent?

Its trust score is 97 out of 100 (excellent). It passes 5 of the 6 static security checks run so far; the failures are listed above. It has no ConduID identity yet, so agent calls to it are not receipted.

Is DBHub still maintained?

Yes — the latest release is v1.5.0 (9 Oct 2026), and the last commit was 5 days ago. The repository has 3.7K stars and 2 open issues.