ClickHouse

● Active

io.github.burakdirin/clickhouse-mcp-server

Query ClickHouse databases from AI assistants, read-only by default with opt-in writes.

Connect this server

One click to install, or copy the config below. Suits: Claude Desktop · Cursor.

Add to Cursor Add to VS CodeClaude Desktop / Claude Code: paste the config below.

Or add it manually — claude_desktop_config.json (Claude Desktop) or .cursor/mcp.json (Cursor):

{
  "mcpServers": {
    "clickhouse-mcp-server": {
      "command": "uvx",
      "args": [
        "clickhouse-mcp-server"
      ],
      "env": {
        "CLICKHOUSE_HOST": "<your CLICKHOUSE_HOST>",
        "CLICKHOUSE_USER": "default",
        "CLICKHOUSE_PASSWORD": "<your CLICKHOUSE_PASSWORD>",
        "CLICKHOUSE_SECURE": "false",
        "CLICKHOUSE_VERIFY": "true",
        "CLICKHOUSE_ALLOW_WRITE": "false",
        "CLICKHOUSE_QUERY_TIMEOUT": "30",
        "CLICKHOUSE_MAX_ROWS": "1000"
      }
    }
  }
}
One line, from the terminal
Claude Code
claude mcp add --env CLICKHOUSE_HOST='<your CLICKHOUSE_HOST>' --env CLICKHOUSE_USER=default --env CLICKHOUSE_PASSWORD='<your CLICKHOUSE_PASSWORD>' --env CLICKHOUSE_SECURE=false --env CLICKHOUSE_VERIFY=true --env CLICKHOUSE_ALLOW_WRITE=false --env CLICKHOUSE_QUERY_TIMEOUT=30 --env CLICKHOUSE_MAX_ROWS=1000 --transport stdio clickhouse-mcp-server -- uvx clickhouse-mcp-server
OpenAI Codex CLI
codex mcp add clickhouse-mcp-server --env CLICKHOUSE_HOST='<your CLICKHOUSE_HOST>' --env CLICKHOUSE_USER=default --env CLICKHOUSE_PASSWORD='<your CLICKHOUSE_PASSWORD>' --env CLICKHOUSE_SECURE=false --env CLICKHOUSE_VERIFY=true --env CLICKHOUSE_ALLOW_WRITE=false --env CLICKHOUSE_QUERY_TIMEOUT=30 --env CLICKHOUSE_MAX_ROWS=1000 -- uvx clickhouse-mcp-server
VS Code
code --add-mcp '{"name":"clickhouse-mcp-server","type":"stdio","command":"uvx","args":["clickhouse-mcp-server"],"env":{"CLICKHOUSE_HOST":"<your CLICKHOUSE_HOST>","CLICKHOUSE_USER":"default","CLICKHOUSE_PASSWORD":"<your CLICKHOUSE_PASSWORD>","CLICKHOUSE_SECURE":"false","CLICKHOUSE_VERIFY":"true","CLICKHOUSE_ALLOW_WRITE":"false","CLICKHOUSE_QUERY_TIMEOUT":"30","CLICKHOUSE_MAX_ROWS":"1000"}}'

Syntax from each client's docs (Claude Code: claude mcp add; Codex: codex mcp add; VS Code: code --add-mcp). Placeholders in angle brackets are values you fill in.

Environment variables
  • CLICKHOUSE_HOSTrequiredClickHouse host name or IP address, without scheme or port.
  • CLICKHOUSE_USERUser name; use a dedicated user with SELECT grants only.
  • CLICKHOUSE_PASSWORDsecretPassword of the ClickHouse user.
  • CLICKHOUSE_SECUREConnect over HTTPS.
  • CLICKHOUSE_VERIFYVerify the server's TLS certificate.
  • CLICKHOUSE_ALLOW_WRITEOffer the clickhouse_execute tool, which can change data and schema.
  • CLICKHOUSE_QUERY_TIMEOUTSeconds before ClickHouse stops a statement.
  • CLICKHOUSE_MAX_ROWSMost rows clickhouse_query returns.

A starting point — check the repository for exact arguments and setup. Restart your client after editing the config.

Category
Databases
Version
0.2.0
Registry
active
Published
Dec 3, 2026
Listed in:Official MCP registry ↗how this is checked

Is it safe? Is it maintained?

Serverdex check: Dec 5, 2026

Looks healthy: ClickHouse is maintained, open source.

Maintained
Active
Last commit today (Dec 3, 2026), 0 open issues.
Official registry
Active
Published as io.github.burakdirin/clickhouse-mcp-server in the official MCP registry, version 0.2.0.
Source
Open source, MIT
Public repository under the MIT licence, 2 stars, 4 forks.
Runs
On your machine
A local PyPI package started by your client; it can reach whatever your user account can.
Credentials
2 required
Declared environment variables: CLICKHOUSE_HOST, CLICKHOUSE_PASSWORD. They stay on your machine; the config on this page shows where each goes.
Owner
Unclaimed
Nobody has claimed this page yet; the data above comes from the registry, GitHub and the live check.

Facts only: last commit and licence from GitHub, the entry's status from the official registry, credentials from the live check. Not a code audit — run the security scan on the endpoint yourself.

A

Grade A · Production-ready

Maintenance & production-readiness — 80/100 from the six repository signals below. A comparable rollup, not a code audit.

  • Recent commits+30/30

    Last commit today.

  • Open licence+15/15

    MIT on GitHub.

  • Documentation+15/15

    The repository ships a README.

  • Adoption0/20

    2 GitHub stars.

  • Registry status+12/12

    Active in the official MCP registry.

  • Product surface+8/8

    Has a homepage or a published package/endpoint.

Own this server? Add the grade badge — it links back here

<a href="https://serverdex.io/server/io-github-burakdirin-clickhouse-mcp-server?utm_source=report-badge"><img src="https://serverdex.io/server/io-github-burakdirin-clickhouse-mcp-server/report-badge.svg" alt="ClickHouse — Serverdex Report Card A" height="22"></a>

Compare every server's grade on best-maintained MCP servers.

On GitHub

read Dec 4, 2026
Stars
2
Forks
4
Last push
Dec 3, 2026
License
MIT

Pythonclaudeclickhousedatabasellmmcpmcp-servermodel-context-protocol

From the README

ClickHouse MCP Server An MCP server that lets AI assistants explore and query a ClickHouse database. It is read-only by default: writing needs an explicit opt-in. It talks to ClickHouse over HTTP(S) with the official clickhouse-connect client and runs over stdio. Tools Both tools take a single sql argument holding exactly one statement; ClickHouse's HTTP interface does not accept several statements per request. Use fully qualified database.table names. There is no tool for switching databases: CLICKHOUSE_DATABASE only sets the default. clickhouse_query only runs statements that start with SELECT, WITH, SHOW, DESC, DESCRIBE, EXISTS or EXPLAIN, and ClickHouse runs them in read-only mode: either the user is already read-only, or the server switches every request to readonly = 1 (see Security). Results are streamed and capped at CLICKHOUSEMAXROWS rows and 256 KB of UTF-8 row data; truncated is true when more data matched. Each response carries the rows twice, as structured content and as the same JSON in text, so it stays under about 512 KB. Integers beyond 2^53 and Decimals that a float cannot hold exactly are returned as strings, NaN and Inf as null, dates and times as strings, named tuples as objects, and invalid UTF-8 with replacement characters. The server sets the output settings that give this representation; for a readonly = 1 user, who may not change them, the profile's own output settings apply. Installation You need uv.…

Read the full README on GitHub →

The most-starred Databases servers in the index, with their live-check result.

ServerStarsLast pushLive check
Dbx31,377Nov 2026Local / not checked
MCP Toolbox for Databases17,062Dec 2026Local / not checked
MCP Toolbox for Databases17,062Dec 2026Local / not checked
Finance Database9,702Nov 2026Working
DBHub4,064Dec 2026Local / not checked

ClickHouse: questions people ask

Is ClickHouse a remote or a local MCP server?
According to its entry in the official MCP registry, ClickHouse ships as a local package (PyPI) that your client starts on your machine.
Does ClickHouse need an API key?
Its registry entry declares 2 required environment variables: CLICKHOUSE_HOST, CLICKHOUSE_PASSWORD. The config on this page shows where each goes.
Is ClickHouse safe to use?
Looks healthy: ClickHouse is maintained, open source. In detail — maintained: Active; official registry: Active; source: Open source, MIT; runs: On your machine; credentials: 2 required. Serverdex check of Dec 5, 2026. This is a reading of the repository, the registry entry and the live check, not a code audit; run the Serverdex security scan on the endpoint before trusting it with real data.
Is ClickHouse still maintained?
Active: the repository's last commit today. Last push Dec 3, 2026, 2 GitHub stars, MIT licence. Read from GitHub on Dec 4, 2026.
How do I add ClickHouse to Claude, Cursor or VS Code?
Copy the config in "Connect this server" into your client's MCP config file (claude_desktop_config.json, ~/.cursor/mcp.json or .vscode/mcp.json), or use the one-click Add to Cursor / Add to VS Code buttons and the one-line commands for Claude Code and Codex; then restart the client.
  1. MySQLQuery MySQL databases from AI assistants, read-only by default with opt-in writes.★ 10
Browse all Databases →

Add the badge to your site

Show visitors that ClickHouse is listed here — it’s also the link we check for a free listing.

ClickHouse — listed on Serverdex

HTML — for your website

<a href="https://serverdex.io/server/io-github-burakdirin-clickhouse-mcp-server?utm_source=badge"><img src="https://serverdex.io/brand/badge.svg" alt="ClickHouse — listed on Serverdex" width="123" height="40" loading="lazy"></a>

Recommended. A dofollow link from your own domain is the one that counts for search engines, and it's the link we check for a free listing.

Markdown — for your README

[![ClickHouse — listed on Serverdex](https://serverdex.io/brand/badge.svg)](https://serverdex.io/server/io-github-burakdirin-clickhouse-mcp-server?utm_source=badge)

Nice for visibility, but GitHub marks README links nofollow, so it doesn't pass authority. Use the HTML badge on your site as well.

Add to CursorAdd to VS CodeOpen in Claude Code

Install buttons — for your README

[![Add to Cursor](https://serverdex.io/brand/install-cursor.svg)](https://serverdex.io/install/cursor/io-github-burakdirin-clickhouse-mcp-server) [![Add to VS Code](https://serverdex.io/brand/install-vscode.svg)](https://serverdex.io/install/vscode/io-github-burakdirin-clickhouse-mcp-server) [![Open in Claude Code](https://serverdex.io/brand/install-claude-code.svg)](https://serverdex.io/install/claude-code/io-github-burakdirin-clickhouse-mcp-server)

One click opens Cursor or VS Code with this server's config prefilled; the Claude Code button lands on the one-line command. The links point at Serverdex, so when your config changes the buttons keep working.

Install buttons — HTML for your docs

<a href="https://serverdex.io/install/cursor/io-github-burakdirin-clickhouse-mcp-server"><img src="https://serverdex.io/brand/install-cursor.svg" alt="Add to Cursor — via Serverdex" width="140" height="28"></a>
<a href="https://serverdex.io/install/vscode/io-github-burakdirin-clickhouse-mcp-server"><img src="https://serverdex.io/brand/install-vscode.svg" alt="Add to VS Code — via Serverdex" width="147" height="28"></a>
<a href="https://serverdex.io/install/claude-code/io-github-burakdirin-clickhouse-mcp-server"><img src="https://serverdex.io/brand/install-claude-code.svg" alt="Open in Claude Code — via Serverdex" width="180" height="28"></a>

Same buttons as plain links for a docs page or website.

Prefer a live badge with the score, stars and live check? Score badge (links to a page that explains the number and back to this listing).