What type of queries does ClickHouse MCP Server allow?
The server only allows read-only SQL queries and performs basic validation to prevent DDL or DML statement execution.
@bjpadhy
基本情報
A Model Context Protocol (MCP) server that connects to ClickHouse databases and allows LLMs like Claude to explore and analyze data through natural language queries.
以下の設定を使って、このサーバーを MCP 対応クライアントに追加してください。
{
"mcpServers": {
"clickhouse-analytics": {
"command": "node",
"args": [
"/absolute/path/to/clickhouse-mcp-server/dist/index.js"
],
"env": {
"CLICKHOUSE_URL": "",
"CLICKHOUSE_USERNAME": "",
"CLICKHOUSE_PASSWORD": "",
"CLICKHOUSE_DATABASE": ""
}
}
}
}Run a read-only SQL query against the database
Ask questions about your data in natural language
ClickHouse MCP Server is a Model Context Protocol (MCP) server that connects to ClickHouse databases and enables LLMs like Claude to explore and analyze data through natural language queries.
Clone the repository, install dependencies with npm install, configure environment variables in a .env file (using a read-only database user), and build with npm run build. Run locally with npm start, or integrate with Claude Desktop by adding the server configuration to claude_desktop_config.json.
The server only allows read-only SQL queries and performs basic validation to prevent DDL or DML statement execution.
It connects to any ClickHouse database configured via environment variables (CLICKHOUSE_URL, CLICKHOUSE_USERNAME, CLICKHOUSE_PASSWORD, CLICKHOUSE_DATABASE).
Add the server configuration to your Claude Desktop config file at `~/Library/Application Support/Claude/claude_desktop_config.json` with the command `node` and absolute path to the built `index.js`.
Resources: `db://info`, `table://{tableName}/schema`, `table://{tableName}/sample`. Tools: `execute-sql` (read-only query) and `natural-language-query`.
Always use a read-only database user, store credentials in environment variables, and review query requests before execution.

Model Context Protocol Servers
The Xata MCP server lets AI assistants and agents interact with your Xata organizations, projects, and Postgres database branches.
Local MCP server for DuckDB and MotherDuck
The official Redis MCP Server is a natural language interface designed for agentic applications to manage and search data in Redis efficiently
Zero-dependency, token-efficient database MCP server for Postgres, MySQL, SQL Server, MariaDB, SQLite.
コメント