ClickHouse
CommunityMCP server by ClickHouse · updated · ★ 889
Official ClickHouse MCP server for querying and exploring ClickHouse clusters and chDB. ClickHouse is a community project by ClickHouse, not verified by a company domain.
Last commit 3 days ago
Apache-2.0: permissive, fine for commercial use
Clear description, published package or server URL, 889 stars, original repository
No risky patterns in the files we checked
What you need
| Setting | Needed | What it is |
|---|---|---|
CLICKHOUSE_Environment variable | Required | Hostname of the ClickHouse server |
CLICKHOUSE_Environment variable | Required | Username for ClickHouse authentication |
CLICKHOUSE_Environment variable, secret | Optional | Password for ClickHouse authentication. Required unless a client certificate uses the default or mutual TLS mode |
CLICKHOUSE_Environment variable | Optional | ClickHouse HTTP(S) port. Defaults to 8443 when CLICKHOUSE_SECURE=true, 8123 otherwise |
CLICKHOUSE_Environment variable | Optional | Use HTTPS to connect to ClickHouse Default: true |
CLICKHOUSE_Environment variable | Optional | Verify SSL certificates Default: true |
CLICKHOUSE_Environment variable | Optional | Path to a PEM CA bundle for ClickHouse server certificate verification |
CLICKHOUSE_Environment variable | Optional | Path to a PEM client certificate for the ClickHouse HTTPS connection |
CLICKHOUSE_Environment variable | Optional | Path to the PEM private key for CLICKHOUSE_CLIENT_CERT |
CLICKHOUSE_Environment variable | Optional | Client certificate mode: mutual, proxy, or strict |
CLICKHOUSE_Environment variable | Optional | Default database to use |
CLICKHOUSE_Environment variable | Optional | ClickHouse role to activate for the session |
CLICKHOUSE_Environment variable | Optional | Allow write operations (DDL and DML). Queries run read-only by default Default: false |
CLICKHOUSE_Environment variable | Optional | Allow destructive operations (DROP, TRUNCATE, DELETE, UPDATE, REPLACE, CLEAR, and DETACH PERMANENTLY) when write access is also enabled Default: false |
CLICKHOUSE_Environment variable | Optional | Query tool timeout in seconds Default: 30 |
CLICKHOUSE_Environment variable | Optional | Maximum query worker thread pool size Default: 10 |
From the publisher's entry in the official MCP Registry. Required settings are already in the install config below as placeholders.
Install ClickHouse
Built from the published package, never by AIclaude mcp add clickhouse -e CLICKHOUSE_HOST=YOUR_CLICKHOUSE_HOST -e CLICKHOUSE_USER=YOUR_CLICKHOUSE_USER -- uvx mcp-clickhouseRun in your terminal. Add --scope user to use it in every project.
{
"mcpServers": {
"clickhouse": {
"command": "uvx",
"args": [
"mcp-clickhouse"
],
"env": {
"CLICKHOUSE_HOST": "YOUR_CLICKHOUSE_HOST",
"CLICKHOUSE_USER": "YOUR_CLICKHOUSE_USER"
}
}
}
}Settings, Developer, Edit config. Paste into claude_desktop_config.json and restart.
{
"mcpServers": {
"clickhouse": {
"command": "uvx",
"args": [
"mcp-clickhouse"
],
"env": {
"CLICKHOUSE_HOST": "YOUR_CLICKHOUSE_HOST",
"CLICKHOUSE_USER": "YOUR_CLICKHOUSE_USER"
}
}
}
}Add to ~/.cursor/mcp.json (all projects) or .cursor/mcp.json (this project).
{
"servers": {
"clickhouse": {
"command": "uvx",
"args": [
"mcp-clickhouse"
],
"env": {
"CLICKHOUSE_HOST": "YOUR_CLICKHOUSE_HOST",
"CLICKHOUSE_USER": "YOUR_CLICKHOUSE_USER"
}
}
}
}Add to .vscode/mcp.json. VS Code uses "servers", not "mcpServers".
codex mcp add clickhouse --env CLICKHOUSE_HOST=YOUR_CLICKHOUSE_HOST --env CLICKHOUSE_USER=YOUR_CLICKHOUSE_USER -- uvx mcp-clickhouse{
"mcpServers": {
"clickhouse": {
"command": "uvx",
"args": [
"mcp-clickhouse"
],
"env": {
"CLICKHOUSE_HOST": "YOUR_CLICKHOUSE_HOST",
"CLICKHOUSE_USER": "YOUR_CLICKHOUSE_USER"
}
}
}
}Add to ~/.gemini/config/mcp_config.json (all projects) or .agents/mcp_config.json (this project).
gemini mcp add clickhouse uvx mcp-clickhouseGemini CLI was replaced by Antigravity CLI in June 2026 and remains only for enterprise licences and paid API keys.
MCP servers run with your permissions and can read what you give them access to. Some need an API key: check the README and add it under env in the clickhouse block.
Weekly newsletter
Like ClickHouse? Get the best new MCP servers every week
The best new tools, security warnings before you install something risky, and one practical tip. Free, three minute read.
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: README.md. This looks for known risky patterns and is not a full audit. How grades work
Alternatives to ClickHouse
All alternatives →MCP server for interacting with the Supabase platform
Built-in MCP server for ArcadeDB multi-model database (graph, document, vector, time-series)
MCP Toolbox for Databases enables your agent to connect to your database.
MCP Toolbox for Databases enables your agent to connect to your database.
Real-time Kubernetes network traffic visibility and API analysis for HTTP, gRPC, Redis, Kafka, DNS.
Self-learning vector database for Node.js — hybrid search, Graph RAG, FlashAttention-3, HNSW, 50+ attention mechanisms
ClickHouse: common questions
How do I install ClickHouse?
In Claude Code run claude mcp add clickhouse -e CLICKHOUSE_HOST=YOUR_CLICKHOUSE_HOST -e CLICKHOUSE_USER=YOUR_CLICKHOUSE_USER -- uvx mcp-clickhouse. For Claude Desktop, Cursor and VS Code, paste the config shown above and restart. See the install guides.
Is ClickHouse the official server?
ClickHouse is a community project by ClickHouse, not verified by a company domain.
Is ClickHouse free?
The code is published under the Apache-2.0 licence. The service it connects to may have its own pricing.
Is ClickHouse safe to use?
It scores 87 of 100. Grades: maintenance A, licence A, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to ClickHouse?
Similar MCP servers: Supabase, ArcadeDB MCP Server, MCP Toolbox for Databases, MCP Toolbox for Databases.
Does ClickHouse work with ChatGPT?
Not directly. It runs locally, and ChatGPT only connects to remote servers with a URL. Use it in Claude Code, Claude Desktop, Cursor, VS Code or Codex.
