ClickHouse MCP server for Claude, ChatGPT and Cursor

Ask "what were the top pages by unique visitors yesterday?" and your assistant queries ClickHouse for the real numbers. SaturnSQL's hosted MCP server works with ClickHouse Cloud and self-hosted servers, no local process to run.

ClaudeMCP · clickhouse
You
What were the top pages by unique visitors yesterday?
execute_query
SELECT path, uniqExact(visitor_id) AS visitors
FROM events
WHERE event_date = yesterday()
GROUP BY path
ORDER BY visitors DESC
LIMIT 3;
pathvisitors
/pricing4812
/3977
/docs2150
Claude
/pricing had the most unique visitors yesterday, about 4.8k.

Setup

1. Add your ClickHouse connection in SaturnSQL. ClickHouse Cloud connects over HTTPS on port 8443, self-hosted servers over the HTTP interface on 8123, directly or through an SSH tunnel.

2. Click your name in the sidebar, then Install MCP, and pick your client: Claude, ChatGPT, Cursor or Claude Code. You add https://mcp.saturnsql.com/mcp and sign in with your SaturnSQL account, with no API key to copy.

What it can do

The connector gives your assistant eight tools: list your connections, read a schema (tables, columns and foreign keys), run SQL, browse and open your team's saved queries, run one of them with its variables filled in, save a new query back to that library, and export a result as CSV, JSON or Excel. Queries get the same row limits as the SaturnSQL editor, and the same read-only check on connections in read-only mode (the default), and billing, users and account settings are never reachable.

It works with PostgreSQL, MySQL and MariaDB, SQL Server, Oracle, Amazon Redshift, ClickHouse, BigQuery and DynamoDB. Your database password stays encrypted in SaturnSQL; the assistant only ever sees results.

Other ClickHouse MCP servers

ClickHouse maintains an open-source MCP server, and ClickHouse Cloud also offers a hosted one for Cloud services.

ServerRuns asWorks withRead-only
ClickHouse Cloud remote MCPHosted by ClickHouse, OAuth or API keyClickHouse Cloud services onlyAll tools are read-only
mcp-clickhouseLocal process (or self-hosted HTTP)Any ClickHouseRead-only unless write access is switched on
MCP Toolbox for Databases (Google)Binary you run and configure yourselfBigQuery, Cloud SQL, AlloyDB, Postgres, MySQL, SQL Server, Oracle, ClickHouse and moreDepends on the tools you define per source
SaturnSQLHosted, OAuthClickHouse and every other engine SaturnSQL connects toRead-only mode (on for new connections): one SELECT, WITH or EXPLAIN statement per call

Checked against each project's docs on 8 October 2026.

On ClickHouse Cloud alone, the Cloud remote server is the simplest start. SaturnSQL fits self-hosted ClickHouse, teams that also query Postgres or MySQL, and teams that want the queries the assistant writes in a shared library. For every engine side by side, see the best MCP servers for databases.

Common questions

What plan do I need? The MCP server is included on SaturnSQL Starter and above. The free plan can try the editor, but it cannot connect an AI client.

Does the assistant see my database password? No. The connection and its credentials stay encrypted in SaturnSQL. Your AI client signs in with your SaturnSQL account and only receives query results.

Can it change or delete data? Not unless you allow it. New connections start in read-only mode, where every query must be a single SELECT, WITH or EXPLAIN statement. Keep read-only mode on for the connections your AI client uses, and connect with a read-only database user as well.

Does it work with ClickHouse Cloud and self-hosted ClickHouse? Yes. ClickHouse Cloud connects over HTTPS on port 8443 and self-hosted servers over the HTTP interface, usually port 8123, with an SSH tunnel if the server is private.

Other databases and clients

The same server connects PostgreSQL, MySQL and MariaDB, SQL Server, Oracle, Amazon Redshift, ClickHouse, BigQuery and DynamoDB. Setting up a specific assistant? See Claude, ChatGPT, Cursor and Claude Code.

Get answers from your ClickHouse data