What it does
The server exposes ClickHouse to MCP-compatible clients through three tools. run_query executes SQL on a cluster and accepts optional named parameters for ClickHouse {name:Type} placeholders. list_databases lists the databases on a cluster, and list_tables lists tables in a database with pagination, LIKE filters and optional column metadata. Tool responses are JSON-encoded, and integers outside JavaScript's safe range are returned as strings so values stay exact.
A client would reach for it to explore an unfamiliar cluster, draft analytical SQL, or check a query before running it. run_query also accepts DESCRIBE to see a query's output columns and types, and EXPLAIN ESTIMATE to see the parts, rows and marks a SELECT would read, which helps before running an expensive query. Parameterised queries keep values separate from the SQL text.
To run it, point the server at a ClickHouse cluster. Queries run in read-only mode by default, and writes must be enabled explicitly through the CLICKHOUSE_ALLOW_WRITE_ACCESS setting. The server implements MCP protocol version 2026-07-28 and also accepts legacy handshakes from 2024-11-05 through 2025-11-25. Modern clients should send the MCP-Protocol-Version header on every POST request.
Limitations and requirements
Queries are read-only unless CLICKHOUSE_ALLOW_WRITE_ACCESS is set to enable writes. Existing ClickHouse permissions still apply to every query and to reading AGENTS.ROOT. Parameter values stay in MCP tool arguments and can appear in backend errors. ClickHouse 26.3.20.7 substitutes them into query text in system.query_log, system.processes and system.text_log, and parameter binding is not a privacy feature. Null values inside arrays depend on the driver: they work with clickhouse-connect 1.8.0 but fail with the supported minimum 1.0.0. JSON lists and objects cannot bind to Tuple or Map types. With non-empty params, queries containing many unterminated {name: placeholder starts are rejected, including such text in comments or string literals. Python-style %s formatting and $name$ raw binary parameters are not supported.
Safety
Our team has not reviewed this resource. Only automated rules checked it; resources with high-risk signals are not published. These are signals, not a guarantee that installing it is safe. Try it in a sandbox project first.
- Runs code or changes an assistant's behaviour
Sources
- Official MCP Registry first seen 13 Nov 2026 · last seen 13 Nov 2026 · its page on the source
ClickHouse
Official ClickHouse MCP server for querying and exploring ClickHouse clusters and chDB.
v0.7.0As shown on registry.modelcontextprotocol.io when we last read it