DBHub

DBHub

v0.24.0
MIT
databasesqlmulti-databasepostgresmysql

Summary

A universal database MCP server — one integration for PostgreSQL, MySQL, SQL Server, SQLite, and MariaDB.

Features

  • One server for Postgres, MySQL, SQL Server, SQLite, and MariaDB
  • Token-efficient schema exposure for large databases
  • Read-only mode and SSH tunnel support

Installation

Set up this MCP server in your favorite AI agent — copy a ready-made configuration below.

Any MCP-compatible agent

Most agents (Claude, Cursor, Windsurf, VS Code, and more) read a standard mcpServers configuration.

  1. Open your agent's MCP configuration file.
  2. Merge the snippet below into it.
  3. Restart the agent — the "DBHub" tools will be available.
{
  "mcpServers": {
    "dbhub": {
      "command": "npx",
      "args": [
        "-y",
        "@bytebase/dbhub",
        "--transport",
        "stdio",
        "--dsn",
        "postgres://user:pass@localhost:5432/db"
      ]
    }
  }
}

Description

DBHub is a single MCP server that speaks to every common relational database, which saves configuring and maintaining a different server per engine.

Supported databases

PostgreSQL, MySQL, MariaDB, SQL Server, and SQLite, all through one connection-string interface.

What makes it practical

  • Token efficiency. Schema information is exposed compactly, which matters enormously on a database with hundreds of tables — naive schema dumps consume the entire context window before a query is written.
  • Read-only mode, enforced at the server rather than trusted to the model.
  • SSH tunnelling for databases that are not directly reachable, which is most production databases.
  • Multiple transports — stdio for local clients, HTTP for remote deployment.
  • A demo mode with a sample database, so you can evaluate it without pointing it at anything real.

Setup

npx @bytebase/dbhub --transport stdio --dsn "<connection string>". Built and maintained by Bytebase, whose main product is database change management, so the operational instincts show.

Related MCP Servers

Browse all MCP servers →