[Home](/index.md) › [MCP servers](/mcp.md) › PlanetScale MCP server

# PlanetScale MCP server

MCP server

- 26 callable tools
- 6 capabilities

[Installation guide](https://planetscale.com/docs/mcp-server.md)

## Overview

PlanetScale's hosted MCP server gives MCP clients access to PlanetScale organizations, databases, branches, schema, Insights data and the organization payment method. It works with Vitess and Postgres databases on PlanetScale.

### Capabilities

- Browse organizations, databases and branches
- Inspect branch schemas and schema recommendations
- Run read and write SQL queries against PlanetScale databases
- Review query performance, error patterns and query tags in Insights
- Check infrastructure metrics and Postgres server logs
- View invoices and the organization payment method

## Works with

The products your agent can work with through this server.

- [PlanetScale](/tools/planetscale.md): Managed MySQL and Postgres

## Tools

The callable functions your agent uses to work with this server.

### `planetscale_list_organizations`

None. Any valid token can list the organization it belongs to.

### `planetscale_get_organization_billing_payment_method`

read_payment_method

### `planetscale_execute_read_query`

Read-only set, plus the read-query connect and delete permissions above

### `planetscale_execute_write_query`

Read-only set, plus the write-query connect and delete permissions above

### `planetscale_search_documentation`

None None

### `planetscale_list_databases`

List all databases within an organization.

### `planetscale_list_branches`

List all branches within a database.

### `planetscale_get_organization`

Get details about a specific organization.

### `planetscale_get_database`

Get details about a specific database.

### `planetscale_get_branch`

Get details about a database branch.

### `planetscale_get_branch_schema`

Get the schema for a database branch.

### `planetscale_get_insights`

Get query performance insights for a PlanetScale database branch.

### `planetscale_list_regions_for_organization`

List all available regions for an organization.

### `planetscale_list_cluster_size_skus`

List all available cluster size SKUs.

### `planetscale_list_invoices`

List all invoices for an organization.

### `planetscale_get_invoice_line_items`

Get all line items for an invoice, with prorated costs broken down by database branch.

### `planetscale_update_payment_method`

Start Stripe Checkout to add or replace the organization's card.

### `planetscale_get_payment_method_setup`

Check a Checkout setup by setup_id.

### `planetscale_list_schema_recommendations`

List schema recommendations for a database, including indexes and primary key exhaustion.

### `planetscale_list_query_error_patterns`

List failing queries for a database branch, aggregated by error fingerprint.

### `planetscale_list_query_error_executions`

List the individual failed executions behind an error fingerprint.

### `planetscale_get_postgres_logs`

Fetch server logs for a Postgres database branch, newest first.

### `planetscale_list_query_tags`

List the query tags seen on a database branch's queries, with their values and query counts.

### `planetscale_get_query_tag`

Get a single query tag and its values, using a tag ID.

### `planetscale_list_query_tag_summaries`

Group query statistics by the values of one or more query tags.

### `planetscale_get_branch_metrics`

Infrastructure metrics for a branch, including CPU, memory, disk, replication lag and connections.

## Installation

Follow the installation guide for supported clients, authentication and required permissions.

### Add PlanetScale MCP server to Claude Code

Run this in your terminal:

```sh
claude mcp add --transport http planetscale https://mcp.pscale.dev/mcp/planetscale
```

If the server asks you to sign in, run `/mcp` in Claude Code and follow the browser prompt.

### Add PlanetScale MCP server to Cursor

Add it with the Add to Cursor button below, or add it to `.cursor/mcp.json` in your project (`~/.cursor/mcp.json` for every project):

[Add to Cursor](cursor://anysphere.cursor-deeplink/mcp/install?name=planetscale&config=eyJ1cmwiOiJodHRwczovL21jcC5wc2NhbGUuZGV2L21jcC9wbGFuZXRzY2FsZSJ9)

```json
{
  "mcpServers": {
    "planetscale": {
      "url": "https://mcp.pscale.dev/mcp/planetscale"
    }
  }
}
```

### Add PlanetScale MCP server to VS Code

Add it to `.vscode/mcp.json` in your workspace. VS Code uses `servers` rather than `mcpServers`. Or run MCP: Add Server from the Command Palette and choose HTTP.

```json
{
  "servers": {
    "planetscale": {
      "type": "http",
      "url": "https://mcp.pscale.dev/mcp/planetscale"
    }
  }
}
```

### Add PlanetScale MCP server to Codex

Run this in your terminal:

```sh
codex mcp add planetscale --url https://mcp.pscale.dev/mcp/planetscale
```

Or add it to `~/.codex/config.toml`:

```toml
[mcp_servers.planetscale]
url = "https://mcp.pscale.dev/mcp/planetscale"
```

If the server uses OAuth, sign in with `codex mcp login planetscale`.

### Add PlanetScale MCP server to Claude

Add it as a custom connector with this URL:

```
https://mcp.pscale.dev/mcp/planetscale
```

1. Open Customize, then Connectors.
2. Click + Add, then Add custom connector.
3. Name it, paste the URL and click Continue.
4. Choose how to sign in, then click Add.

On Team and Enterprise plans, an Owner adds it in Organization settings first, then members connect it.

### Add PlanetScale MCP server to other clients

For any other client that connects to remote MCP servers over HTTP, use this URL:

```
https://mcp.pscale.dev/mcp/planetscale
```

[Read the installation guide](https://planetscale.com/docs/mcp-server.md)

## Related MCP servers

Other servers for the same products, or from the same vendor.

- [PlanetScale docs MCP](/mcp/planetscale-docs.md)

## Sources

Documentation and source code reviewed on 10 November 2026.

- [planetscale.com/docs/mcp-server.md](https://planetscale.com/docs/mcp-server.md)
- [planetscale.com/docs/mcp/service-token.md](https://planetscale.com/docs/mcp/service-token.md)
- [planetscale.com/docs/api/service-tokens.md](https://planetscale.com/docs/api/service-tokens.md)
