# Sanity MCP

> Sanity's own MCP server: your agent queries and edits your content with GROQ, manages releases and schemas, and deploys Studio.

Sanity's own MCP server, hosted at mcp.sanity.io. It gives your agent direct access to your Sanity projects (content, datasets, releases and schemas) with full awareness of your schema, plus Sanity's docs and best-practice rules, so it can run content operations as well as write code.

What you can do with it
- Run GROQ queries and read documents in your datasets
- Create drafts, patch documents, validate them, and publish or unpublish them
- Create and list Content Releases, and add document versions to them
- Read, list and deploy schemas, and deploy a hosted Sanity Studio
- Upload images and files to a dataset or Media Library, and generate or transform images with AI
- Manage projects, datasets and CORS origins, and search Sanity's docs and best-practice rules

How it connects
Add https://mcp.sanity.io as a remote MCP server. npx sanity@latest mcp configure sets it up for Cursor, VS Code and Claude Code using your Sanity CLI login. In Claude Code, Sanity's plugin adds the same server along with its agent skills and the /sanity, /sanity-review, /typegen and /deploy-schema commands.

Signing in
It uses OAuth by default and asks you to sign in to Sanity. You can use an API token instead by setting an Authorization header; tool calls then follow that token's role and permissions.

Good to know
- Documents it creates or edits are drafts until you publish them.
- generate_image and transform_image use Sanity AI credits; you can turn those tools off in your MCP client.
- Which tools you see depends on your permissions for the project and dataset.

- Type: Plugin
- Made by: Sanity
- Category: Developer tools
- Formats: Remote MCP, Claude plugins
- Version: latest
- Website: https://www.sanity.io/
- Source: https://github.com/sanity-io/agent-toolkit
- Page: https://pluginboard.ai/plugins/sanity-mcp

## Works with

- ChatGPT
- Claude
- Muse
- Grok Bot
- Gemini
- Grok
- GitHub Copilot
- Cursor
- Claude Code
- Codex
- Antigravity
- Gemini CLI
- Replit
- OpenClaw
- OpenCode
- Hermes Agent

## Install

### ChatGPT

In ChatGPT on the web: Plugins → + → Add custom MCP server, then paste https://mcp.sanity.io under Connection. Business and Enterprise plans; Pro can add read-only servers.

### Claude

In Claude (web or desktop): Customize → Plugins → Add → Add marketplace, enter anthropics/knowledge-work-plugins, then add sanity-plugin

### Muse

In Muse: In a Muse chat, ask it to create a custom connector for the MCP server at https://mcp.sanity.io. Then tap Connect on the card it shows and sign in, or add your key.

### Grok Bot

In Grok Bot: In a chat with your Bot, say "Add this MCP server: https://mcp.sanity.io". It confirms the details with you and sets it up, and the tools are ready from your next message.

### Gemini

In Gemini: At gemini.google.com: Settings → Connected Apps → Add a custom app, then paste https://mcp.sanity.io

### Grok

In Grok on the web: At grok.com/connectors: New Connector → Custom, then enter https://mcp.sanity.io and sign in if it asks.

### GitHub Copilot

Add to VS Code: vscode:mcp/install?%7B%22name%22%3A%22sanity-mcp%22%2C%22type%22%3A%22http%22%2C%22url%22%3A%22https%3A%2F%2Fmcp.sanity.io%22%7D

Copilot CLI:

```shell
copilot mcp add --transport http sanity-mcp https://mcp.sanity.io
```

### Cursor

Add to Cursor: cursor://anysphere.cursor-deeplink/mcp/install?name=sanity-mcp&config=eyJ1cmwiOiJodHRwczovL21jcC5zYW5pdHkuaW8ifQ%3D%3D

Add to .cursor/mcp.json:

```json
{
  "mcpServers": {
    "sanity-mcp": {
      "url": "https://mcp.sanity.io"
    }
  }
}
```

### Claude Code

In Claude Code:

```text
/plugin marketplace add anthropics/knowledge-work-plugins
/plugin install sanity-plugin@knowledge-work-plugins
```

### Codex

Run in your terminal:

```shell
codex mcp add sanity-mcp --url https://mcp.sanity.io
```

### Antigravity

Add to ~/.gemini/config/mcp_config.json:

```json
{
  "mcpServers": {
    "sanity-mcp": {
      "url": "https://mcp.sanity.io"
    }
  }
}
```

### Gemini CLI

Run in your terminal:

```shell
gemini mcp add --transport http sanity-mcp https://mcp.sanity.io
```

### Replit

In Replit: At replit.com/integrations, open MCP Servers → + Add MCP server, paste https://mcp.sanity.io (add any headers under Advanced settings), then click Test & save.

### OpenClaw

Run in your terminal:

```shell
openclaw mcp add sanity-mcp --url https://mcp.sanity.io --transport streamable-http
```

If it needs a key or sign-in: For https://mcp.sanity.io, add --header NAME=value for each header it needs, or --auth oauth and then run openclaw mcp login sanity-mcp.

### OpenCode

Run in your terminal:

```shell
opencode mcp add sanity-mcp --url https://mcp.sanity.io
```

If it needs a key: For https://mcp.sanity.io, add --header 'NAME=value' for each header it needs. Add --global to use it in every project.

### Hermes Agent

Run in your terminal:

```shell
hermes mcp add sanity-mcp --url https://mcp.sanity.io
```

Add to ~/.hermes/config.yaml:

```json
{
  "mcp_servers": {
    "sanity-mcp": {
      "url": "https://mcp.sanity.io"
    }
  }
}
```

If it signs in with OAuth: If https://mcp.sanity.io asks you to sign in, add --auth oauth to the command, or auth: oauth to its entry.

---
From Pluginboard (https://pluginboard.ai).
