Yugabytedb MCP Server

An [MCP](https://modelcontextprotocol.io/) server for YugabyteDB and PostgreSQL — lets LLMs (Claude Desktop, Cursor, Windsurf, etc.) summarize

Remote serverstreamable-httpPython

What is the Yugabytedb MCP server?

Yugabytedb mcp server connects Yugabytedb to AI assistants that speak the Model Context Protocol. An MCP server for YugabyteDB and PostgreSQL — lets LLMs (Claude Desktop, Cursor, Windsurf, etc.) summarize schemas, run read-only queries, and execute write statements behind a configurable guardrail layer.

What Yugabytedb does

An MCP server for YugabyteDB and PostgreSQL — lets LLMs (Claude Desktop, Cursor, Windsurf, etc.) summarize schemas, run read-only queries, and execute write statements behind a configurable guardrail layer.

Key capabilities

  • summarize_database — — list tables with columns and row counts for a schema (read-only)
  • run_read_only_query — — execute a SELECT under BEGIN READ ONLY; results returned as JSON (read-only)
  • run_write_query — — INSERT/UPDATE/DELETE/MERGE/TRUNCATE/DDL gated by a guardrail blocklist (destructive, disabled by default — enable with --enable-write-query or YB_MCP_ENABLE_WRITE_QUERY=true)

Installing the yugabytedb mcp server

The server is distributed via npm as @modelcontextprotocol/inspector, so most clients can run it without a manual build step. Add it to your MCP client's configuration and restart the client to pick it up — the copy-paste configs for Claude Desktop, Claude Code and Cursor are on this page.

Configuration

Before the server will start you need to supply 8 environment variables: YUGABYTEDB_URL, YB_LOG_LEVEL, MCP_AUTH_PROVIDER, MCP_BASE_URL, COGNITO_USER_POOL_ID, COGNITO_AWS_REGION, COGNITO_CLIENT_ID, COGNITO_CLIENT_SECRET. Keep credentials in your client's env block or a secrets manager rather than committing them.

Requirements

  • Python 3.10+ - uv (recommended) or pip - A reachable YugabyteDB or PostgreSQL database - An MCP client (Claude Desktop, Cursor, Windsurf, etc.)

Where it fits

Database servers turn schema archaeology and ad-hoc reporting into conversation, which is why they tend to be the second or third server people install. Yugabytedb sits in that group. Worth comparing against the other databases servers in this directory before you commit to one, since several overlap in scope but differ sharply in setup cost and permissions.

Practical notes

  • This is a hosted server — you point your client at an endpoint rather than running a local process, so there is nothing to keep updated on your machine.
  • It will not start until its required credentials are present, so set those before wondering why the tools never appear.
  • Maintained by yugabyte, written in Python.
  • MCP clients ask for confirmation before each tool call by default. Keep that on while you learn what the yugabytedb mcp server actually does with your data.
  • Every entry in this directory is reviewed by hand before it goes live, and details are checked against the project's own documentation.

How to install the Yugabytedb MCP server

{
  "mcpServers": {
    "yugabytedb": {
      "command": "uvx",
      "args": ["yugabytedb-mcp-server"],
      "env": {
        "YUGABYTEDB_URL": "host=… port=5433 dbname=… user=… password=…"
      }
    }
  }
}

Configuration as documented by the project. Restart the client after saving.

Configuration

  • Python 3.10+ - uv (recommended) or pip - A reachable YugabyteDB or PostgreSQL database - An MCP client (Claude Desktop, Cursor, Windsurf, etc.)
VariableDescriptionRequired
YUGABYTEDB_URLEndpoint or connection string the server talks to.Yes
YB_LOG_LEVELConfiguration value read at startup.Optional
MCP_AUTH_PROVIDERConfiguration value read at startup.Optional
MCP_BASE_URLEndpoint or connection string the server talks to.Yes
COGNITO_USER_POOL_IDConfiguration value read at startup.Optional
COGNITO_AWS_REGIONConfiguration value read at startup.Optional
COGNITO_CLIENT_IDConfiguration value read at startup.Optional
COGNITO_CLIENT_SECRETCredential the server authenticates with.Yes

Frequently asked questions

It connects Yugabytedb to MCP-compatible AI assistants such as Claude and Cursor. Instead of copying data back and forth by hand, the assistant works with Yugabytedb directly.