# MySQL plugin

> Lets your agent explore your MySQL schemas, query your data in plain English, and check query plans, locks and table health.

Google's MySQL plugin connects your agent to a MySQL database through MCP Toolbox for Databases. Describe what you want in plain English and your agent can explore the schema, query your data, see what's running and generate code that matches your tables. It works with any MySQL instance you can reach; Google makes a separate Cloud SQL for MySQL plugin for Cloud SQL instances.

What you can do with it
- List tables with their columns, constraints, indexes and triggers
- Ask questions of your data and let your agent write and run the SQL
- See a query's execution plan, the queries running now and the locks they hold
- Find tables without a primary or unique key, and fragmented tables
- Review table statistics and query statistics such as latency, rows examined and full table scans
- Generate code from your schema, such as a Python dataclass for a table

How it connects
It installs as a Gemini CLI extension and as a plugin for Claude Code, Codex and Antigravity. It runs MCP Toolbox's prebuilt MySQL server on your machine with npx, so it needs Node.js and a running MySQL instance. You give it the host, port, database, user and password: Gemini CLI asks for them when you install it, Claude Code takes them with --config or from /plugin, and Codex and Antigravity read them from environment variables. Host and port default to localhost and 3306.

Good to know
- execute_sql runs any SQL statement your agent writes, so connect as a MySQL user with only the access you want it to have.
- The connection is set before your agent starts and can't be changed during a session.
- It's in beta (before v1.0), so expect breaking changes.

- Type: Plugin
- Made by: Google
- Category: Databases
- Formats: Claude plugins, Extensions
- Version: 0.1.6
- Website: https://github.com/GoogleCloudPlatform/mysql-plugin
- Source: https://github.com/GoogleCloudPlatform/mysql-plugin
- Page: https://pluginboard.ai/plugins/mysql-plugin

## Works with

- Claude
- GitHub Copilot
- Claude Code
- Gemini CLI
- OpenClaw

## Install

### Claude

In Claude (web or desktop): Customize → Plugins → Add → Add marketplace, enter GoogleCloudPlatform/mysql-plugin, then add mysql

### Claude Code

In Claude Code:

```text
/plugin marketplace add GoogleCloudPlatform/mysql-plugin
/plugin install mysql@mysql
```

### Gemini CLI

Run in your terminal:

```shell
gemini extensions install https://github.com/GoogleCloudPlatform/mysql-plugin
```

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