Skip to main content
mcpSource-backedReview first Safety Privacy

CockroachDB Cloud MCP Server for Claude

Manage CockroachDB Cloud clusters from Claude — list databases and tables, inspect schemas, run SELECT queries, explain query plans, monitor running queries, and optionally create tables and insert data — with the official CockroachDB Cloud MCP server.

HarnessClaude CodeCursorClaude Desktop
Review first review before installing

Open the source and read safety notes before installing.

Safety notes

  • The server is read-only by default — SELECT, EXPLAIN, and schema queries only; no INSERT, UPDATE, or DELETE.
  • Write tools (create_database, create_table, insert_rows) can be enabled with explicit opt-in — only enable if needed.
  • DROP and TRUNCATE operations are not supported even with write opt-in.

Privacy notes

  • Database schemas, table structures, query results, and running query metadata from your CockroachDB Cloud cluster are surfaced in Claude's context.
  • Authentication uses OAuth (browser flow) or a service account API key — keep the API key in the MCP config headers.

Prerequisites

  • A CockroachDB Cloud account with at least one cluster — sign up at cockroachlabs.com.
  • Your cluster ID (from the Cloud Console URL: cockroachlabs.cloud/cluster/YOUR_CLUSTER_ID).
  • An MCP client such as Claude Code or Claude Desktop.
  • Optional: a CockroachDB Cloud service account API key for non-interactive auth.

Schema details

Install type
cli
Troubleshooting
No
Collection metadata
Estimated setup
5 minutes
Difficulty
beginner
Tool listing metadata
Disclosure
CockroachDB is a commercial distributed SQL database. The MCP server is officially maintained by Cockroach Labs.
Full copyable content
{
  "mcpServers": {
    "cockroachdb": {
      "type": "http",
      "url": "https://cockroachlabs.cloud/mcp",
      "headers": {
        "mcp-cluster-id": "YOUR_CLUSTER_ID"
      }
    }
  }
}

About this resource

Overview

The CockroachDB Cloud MCP Server is the official remote Model Context Protocol server from Cockroach Labs for CockroachDB Cloud. It connects Claude directly to your CockroachDB Cloud clusters via the hosted endpoint at https://cockroachlabs.cloud/mcp — no local install required. Read-only by default (SELECT, EXPLAIN, schema queries), with optional write capability for CREATE and INSERT operations. Authentication via OAuth browser flow or service account API key.

Key capabilities

  • Cluster listing — list all accessible clusters.
  • Schema exploration — list databases, tables, and get full table schemas.
  • SQL queries — execute SELECT statements against your cluster.
  • Query plans — run EXPLAIN on queries to diagnose performance.
  • Active query monitoring — show currently running queries.
  • Write operations (opt-in) — create databases and tables, insert rows.

Tools

Tool Category Purpose
list_clusters Discovery List all accessible clusters
get_cluster Discovery Detailed cluster info
list_databases Schema List databases in a cluster
list_tables Schema List tables in a database
get_table_schema Schema Full table schema
select_query SQL Execute SELECT statements
explain_query SQL Run EXPLAIN on a query
show_running_queries Monitoring Monitor active queries
create_database Write (opt-in) Create a new database
create_table Write (opt-in) Define a new table
insert_rows Write (opt-in) Insert rows

How it compares

Server Read-only default Schema inspection Query explain No local install Notes
CockroachDB Cloud MCP Yes Yes Yes Yes Official, hosted
Neon MCP No Yes No No Serverless Postgres
PlanetScale MCP Yes Yes No No MySQL
CockroachDB (self-hosted) No Yes Yes No Third-party, OSS

CockroachDB Cloud MCP is unique in providing a read-only default with no local install, connecting directly to managed clusters via a hosted HTTP endpoint.

Installation

Claude Code (OAuth browser login)

claude mcp add cockroachdb \
  https://cockroachlabs.cloud/mcp \
  --transport http \
  --header "mcp-cluster-id: YOUR_CLUSTER_ID"

Run /mcp in Claude Code to complete OAuth authentication.

Claude Code (service account API key)

claude mcp add cockroachdb \
  https://cockroachlabs.cloud/mcp \
  --transport http \
  --header "mcp-cluster-id: YOUR_CLUSTER_ID" \
  --header "Authorization: Bearer YOUR_SERVICE_ACCOUNT_API_KEY"

Find your cluster ID in the Cloud Console URL: cockroachlabs.cloud/cluster/YOUR_CLUSTER_ID.

Claude Desktop

{
  "mcpServers": {
    "cockroachdb": {
      "type": "http",
      "url": "https://cockroachlabs.cloud/mcp",
      "headers": {
        "mcp-cluster-id": "YOUR_CLUSTER_ID"
      }
    }
  }
}

Requirements

  • CockroachDB Cloud account with a cluster.
  • Cluster ID from the Cloud Console.
  • An MCP client (Claude Code or Claude Desktop).
  • No local install required.

Security

  • Read-only by default — no unintended data modification.
  • Service account API keys scope access per principal — use least-privilege keys.
  • DROP and TRUNCATE are not supported even with write opt-in.

Source Verification Notes

Verified on 2026-06-18:

  • Official CockroachDB Cloud MCP documentation at www.cockroachlabs.com/docs/cockroachcloud/connect-to-the-cockroachdb-cloud-mcp-server (SSR HTML, HTTP 200) documents the hosted endpoint https://cockroachlabs.cloud/mcp, the mcp-cluster-id header requirement, OAuth 2.1 and service account API key authentication, all tools, read-only default mode, and opt-in write operations (create_database, create_table, insert_rows; no DROP/TRUNCATE).
  • Claude Code MCP documentation at code.claude.com/docs/en/mcp describes the --transport http connection pattern used above.

Source citations

Add this badge to your README

Show that CockroachDB Cloud MCP Server for Claude is listed on HeyClaude. Paste this Markdown into your README — it renders the badge and links back to this page.

Listed on HeyClaude
[![Listed on HeyClaude](https://heyclau.de/badge/mcp/cockroachdb-mcp-server.svg)](https://heyclau.de/entry/mcp/cockroachdb-mcp-server)

How it compares

CockroachDB Cloud MCP Server for Claude side by side with 3 alternatives on trust, install, platform support, and disclosed safety notes — all from reviewed registry metadata.

FieldCockroachDB Cloud MCP Server for Claude

Manage CockroachDB Cloud clusters from Claude — list databases and tables, inspect schemas, run SELECT queries, explain query plans, monitor running queries, and optionally create tables and insert data — with the official CockroachDB Cloud MCP server.

Open dossier
Aiven MCP Server for Claude

Manage your Aiven cloud database services from Claude — list and monitor PostgreSQL, Apache Kafka, ClickHouse, Valkey, and OpenSearch services, execute SQL queries, manage Kafka topics and schemas, tail logs, and optimize queries — with the official Aiven MCP server.

Open dossier
Teradata MCP Server for Claude

Connect Claude to Teradata — list databases and tables, inspect DDL, run SQL queries, preview data, analyze column quality, and explore DBA diagnostics — with the official Teradata MCP server supporting optional ML tool expansion via the teradataml Python package.

Open dossier
MCP SQLite Server for Claude

Read and write any local SQLite database from Claude — get database info, list tables, inspect schemas, create/read/update/delete records, and run raw SQL queries — with the MCP SQLite server that connects to any `.db` file you specify.

Open dossier
Trust
Install riskReview firstReview firstReview firstReview first
Notes Safety Privacy Safety Privacy Safety Privacy Safety Privacy
Categorymcpmcpmcpmcp
Sourcesource-backedsource-backedsource-backedsource-backed
AuthorCockroach LabsAivenTeradatajparkerweb
Added2026-06-182026-06-182026-06-182026-06-18
Platforms
Claude CodeCursorClaude Desktop
Claude CodeClaude Desktop
Claude CodeClaude Desktop
Claude CodeClaude Desktop
Source repo
Safety notesThe server is read-only by default — SELECT, EXPLAIN, and schema queries only; no INSERT, UPDATE, or DELETE. Write tools (create_database, create_table, insert_rows) can be enabled with explicit opt-in — only enable if needed. DROP and TRUNCATE operations are not supported even with write opt-in.Write operations (create/update services, deploy apps) are available but require `AIVEN_READ_ONLY=false` — the server defaults to read-only mode. Aiven services include managed production databases — confirm before creating or modifying services.The `base_query` tool executes arbitrary SQL on your Teradata system — only connect with credentials scoped to the minimum required permissions. Row limits (`DEFAULT_ROW_LIMIT`, `MAX_ROW_LIMIT`) prevent accidental full-table scans returning millions of rows; leave defaults in place unless you need larger result sets.The `query` tool executes arbitrary SQL including INSERT, UPDATE, and DELETE statements — it is not read-only. Point the server at a copy or test database to avoid accidental data loss before trusting it with production data.
Privacy notesDatabase schemas, table structures, query results, and running query metadata from your CockroachDB Cloud cluster are surfaced in Claude's context. Authentication uses OAuth (browser flow) or a service account API key — keep the API key in the MCP config headers.Service metadata, metrics, application logs, PostgreSQL query stats, Kafka topic configurations, and Schema Registry content from your Aiven account are surfaced in Claude's context. Your `AIVEN_TOKEN` grants account-level API access — keep it in the MCP config env and never commit it to version control.Query results, schema definitions, DDL, and session/system metadata from your Teradata instance are surfaced in Claude's context. Your database credentials are embedded in the `DATABASE_URI` — keep it in the MCP config env and never commit it to version control.All database content including table schemas, record data, and query results are surfaced in Claude's context — do not connect databases containing sensitive personal or credential data unless you intend to share it with the model. No credentials are required and no data is sent to external services — the server operates entirely locally.
Prerequisites
  • A CockroachDB Cloud account with at least one cluster — sign up at cockroachlabs.com.
  • Your cluster ID (from the Cloud Console URL: cockroachlabs.cloud/cluster/YOUR_CLUSTER_ID).
  • An MCP client such as Claude Code or Claude Desktop.
  • Optional: a CockroachDB Cloud service account API key for non-interactive auth.
  • An Aiven account — sign up at aiven.io.
  • An Aiven API token: User Information → Authentication → Generate Token.
  • Node.js with `npx` available.
  • An MCP client such as Claude Code or Claude Desktop.
  • A Teradata database instance accessible from your network.
  • A Teradata username and password with appropriate query permissions.
  • Python with `uvx` available.
  • An MCP client such as Claude Code or Claude Desktop.
  • A local SQLite database file (`.db`) you want to connect to.
  • Node.js with `npx` available.
  • An MCP client such as Claude Code or Claude Desktop.
Install
claude mcp add cockroachdb https://cockroachlabs.cloud/mcp --transport http --header "mcp-cluster-id: YOUR_CLUSTER_ID"
claude mcp add --scope user aiven-mcp -e AIVEN_TOKEN=<your-token> -- npx -y mcp-aiven
claude mcp add teradata -e DATABASE_URI="teradata://username:password@host:1025/databasename" -- uvx teradata-mcp-server
claude mcp add sqlite -- npx -y mcp-sqlite /path/to/database.db
Config
{
  "mcpServers": {
    "cockroachdb": {
      "type": "http",
      "url": "https://cockroachlabs.cloud/mcp",
      "headers": {
        "mcp-cluster-id": "YOUR_CLUSTER_ID",
        "Authorization": "Bearer YOUR_SERVICE_ACCOUNT_API_KEY"
      }
    }
  }
}
{
  "mcpServers": {
    "aiven-mcp": {
      "command": "npx",
      "args": ["-y", "mcp-aiven"],
      "env": {
        "AIVEN_TOKEN": "<your-token>",
        "AIVEN_READ_ONLY": "true",
        "AIVEN_SERVICES_SCOPE": "kafka,pg"
      }
    }
  }
}
{
  "mcpServers": {
    "teradata": {
      "command": "uvx",
      "args": ["teradata-mcp-server"],
      "env": {
        "DATABASE_URI": "teradata://username:password@host:1025/databasename",
        "DEFAULT_ROW_LIMIT": "1000",
        "MAX_ROW_LIMIT": "50000"
      }
    }
  }
}
{
  "mcpServers": {
    "sqlite": {
      "command": "npx",
      "args": ["-y", "mcp-sqlite", "/path/to/database.db"]
    }
  }
}
Citations
ClaimUnclaimedUnclaimedUnclaimedUnclaimed

Signals

Loading live community signals…

More like this, weekly

A short, calm digest of reviewed Claude resources. Unsubscribe any time.