DBHub Analytics

io.github.amansingh63Published by GitHub account amansingh63v0.2.0Updated Oct 24, 2026

MCP server for Databricks, BigQuery, PostgreSQL, MySQL, SQL Server, SQLite, MariaDB

VerifiedSTDIODesktop onlyDatabasesData & Analytics

Overview

AI-generated overview

Lets an AI assistant run SQL and browse schemas across PostgreSQL, MySQL, MariaDB, SQL Server, SQLite, Databricks and BigQuery from one interface.

What you can do
DBHub Analytics is a local MCP server that connects MCP clients to one or more databases. Its main tools are execute_sql, which runs SQL with read-only enforcement and row limiting, and search_objects, which browses catalogs, schemas, tables, columns, indexes and routines. Reusable parameterized queries can be defined as custom tools in a dbhub.toml file, and multiple databases can be configured at once.
When to use it
Useful when an assistant should query or explore a database directly, for example asking questions of a Databricks or BigQuery warehouse in natural language, inspecting schemas, or running diagnostic queries against a read replica. It fits teams that want one server covering several database engines.
Requirements
Runs locally via npx (Node.js) or Docker. Needs connection details for each database: a DSN or the DB_HOST, DB_PORT, DB_NAME, DB_USER and DB_PASSWORD variables, plus DB_TYPE. Databricks and BigQuery need tokens or a service account key file; SSH tunneling needs SSH_HOST, SSH_PORT, SSH_USER and a key or password. Network access to the database is required.
Before you install
The server handles database credentials: DSN, DB_PASSWORD, SSH_PASSWORD, SSH_PASSPHRASE and SSH_KEY, and DSNs may embed passwords or Databricks tokens. Although read-only mode and row limits are offered, execute_sql can still run queries against production data, so point it at read replicas or restricted accounts and review the read-only setting before use.

Installation

In SourceWeft

  1. Open DBHub Analytics in the dashboard and add it to a workspace.
  2. Enable the server for the chats that should use its tools.

Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.

Other MCP clients

Follow the launch instructions in the repository.

README

DBHub Analytics

Universal Database MCP Server for Databricks, Google BigQuery, PostgreSQL, MySQL, SQL Server, SQLite, MariaDB

[npm version] [License: MIT]

Built on top of DBHub by Bytebase.

What is DBHub Analytics?

DBHub Analytics is an open-source MCP (Model Context Protocol) server that connects AI assistants like Claude Desktop, Claude Code, Cursor, VS Code Copilot, and other MCP-compatible clients to your databases. Query Databricks SQL warehouses, Google BigQuery datasets, PostgreSQL, MySQL, and more — all through a single unified interface.

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

Key Features

  • Cloud Data Warehouses: Connect to Databricks SQL and Google BigQuery for analytics workloads
  • Traditional Databases: Full support for PostgreSQL, MySQL, MariaDB, SQL Server, SQLite
  • Multi-Database: Connect to multiple databases simultaneously with a single TOML config file
  • Schema Explorer: Progressive disclosure — browse catalogs, datasets, schemas, tables, and columns
  • Safety Guardrails: Read-only mode, row limits, and query timeouts to prevent runaway operations
  • Secure Access: SSH tunneling, SSL/TLS encryption, and service account authentication
  • Zero Config: Just provide a DSN — no drivers to install, no complex setup

Supported Databases

DatabaseDSN ProtocolStatus
PostgreSQLpostgres://Stable
MySQLmysql://Stable
MariaDBmariadb://Stable
SQL Serversqlserver://Stable
SQLitesqlite:///Stable
Databricks SQLdatabricks://Stable
Google BigQuerybigquery://Stable

MCP Tools

ToolDescription
execute_sqlExecute SQL queries with read-only enforcement and row limiting
search_objectsBrowse catalogs, schemas, tables, columns, indexes, and routines
Custom ToolsDefine reusable, parameterized SQL queries in dbhub.toml

Quick Start

NPM (recommended)

bash
npx dbhub-analytics --dsn "postgres://user:password@localhost:5432/dbname"

Databricks SQL

bash
npx dbhub-analytics --dsn "databricks://token:[email protected]/sql/2.0/warehouses/your_warehouse_id"

Google BigQuery

bash
npx dbhub-analytics --dsn "bigquery://your-gcp-project/your_dataset?keyFile=/path/to/service-account.json&location=US"

Docker

bash
docker run --rm --init \   --name dbhub-analytics \   --publish 8080:8080 \   amansingh63/dbhub-analytics \   --transport http \   --port 8080 \   --dsn "postgres://user:password@localhost:5432/dbname"

Demo Mode

bash
npx dbhub-analytics --demo

Connect to Your AI Assistant

Claude Desktop / Claude Code

Add to your claude_desktop_config.json or .mcp.json:

json
{  "mcpServers": {    "dbhub-analytics": {      "command": "npx",      "args": ["-y", "dbhub-analytics", "--dsn", "bigquery://your-project/your_dataset?keyFile=/path/to/sa.json&location=US"]    }  }}

GitHub Copilot (VS Code)

Add to your .vscode/mcp.json:

json
{  "servers": {    "dbhub-analytics": {      "command": "npx",      "args": ["-y", "dbhub-analytics", "--dsn", "postgres://user:pass@localhost:5432/dbname"]    }  }}

Cursor

Add to your Cursor MCP settings (~/.cursor/mcp.json):

json
{  "mcpServers": {    "dbhub-analytics": {      "command": "npx",      "args": ["-y", "dbhub-analytics", "--dsn", "databricks://token:YOUR_TOKEN@host/sql/2.0/warehouses/ID"]    }  }}

Windsurf

Add to your Windsurf MCP config (~/.codeium/windsurf/mcp_config.json):

json
{  "mcpServers": {    "dbhub-analytics": {      "command": "npx",      "args": ["-y", "dbhub-analytics", "--dsn", "mysql://user:pass@localhost:3306/dbname"]    }  }}

Multi-Database via TOML Config

For connecting to multiple databases, use a TOML config file with any of the above clients:

json
{  "mcpServers": {    "dbhub-analytics": {      "command": "npx",      "args": ["-y", "dbhub-analytics", "--config", "/path/to/dbhub.toml"]    }  }}

Configuration

DSN Connection Strings

DatabaseFormat
PostgreSQLpostgres://user:pass@host:5432/dbname?sslmode=require
MySQLmysql://user:pass@host:3306/dbname
MariaDBmariadb://user:pass@host:3306/dbname
SQL Serversqlserver://user:pass@host:1433/dbname
SQLitesqlite:///path/to/file.db or sqlite:///:memory:
Databricksdatabricks://token:TOKEN@host/sql/2.0/warehouses/ID?catalog=CAT&schema=SCH
BigQuerybigquery://PROJECT_ID/DATASET?keyFile=/path/to/key.json&location=US

Multi-Database Setup (TOML)

Connect to multiple databases simultaneously. Create a dbhub.toml file:

toml
[[sources]]id = "databricks_prod"type = "databricks"host = "adb-xxx.azuredatabricks.net"password = "dapi..."path = "/sql/2.0/warehouses/abc123"
[[sources]]id = "bigquery_analytics"type = "bigquery"project = "my-gcp-project"database = "analytics_dataset"location = "US"
[[sources]]id = "postgres_prod"type = "postgres"host = "localhost"port = 5432database = "production"user = "dbuser"password = "secret"

Then run:

bash
npx dbhub-analytics --config dbhub.toml

See Multi-Database Configuration and Command-Line Options for complete documentation.

Use Cases

  • Data Analysts: Ask Claude to query your Databricks or BigQuery data warehouse in natural language
  • Backend Engineers: Explore database schemas, run diagnostic queries, and debug issues via AI
  • DevOps/SRE: Connect to production read-replicas safely with read-only mode and row limits
  • Data Scientists: Query multiple databases simultaneously — join insights across PostgreSQL and BigQuery

Development

bash
# Install dependenciespnpm install
# Run in development modepnpm dev
# Build for productionpnpm build
# Run testspnpm test

Credits

Built on top of DBHub by Bytebase, an open-source database DevSecOps platform. Licensed under MIT.

Source: README.md at commit 3888599

Tools

0
SourceWeft has not started this package in its sandbox yet, so its tools are not known.

Version history

1
  1. v0.2.0LatestSep 16, 2026

Score

50% of the applicable checks met

How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.

  • Reached in the last 30 days25 pts

    Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.

  • Auth declared10 pts

    Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.

  • Tools listed15 pts

    Answer tools/list without a credential, or ship a package that starts in a sandbox without one.

  • DescriptionRequired15 pts
  • Logo10 pts
  • Documentation15 pts
  • License10 pts