easy-mysql-admin-mcp
Provides tools for managing MySQL databases, including listing, creating, dropping databases; creating, altering, and dropping users; granting and revoking privileges; with safety tokens for destructive actions.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@easy-mysql-admin-mcp list databases"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
easy-mysql-admin-mcp
High-privilege MySQL admin MCP server for database and user/grant management.
Features
List, create, and inspect databases
List, create, and update users
Grant and revoke privileges at database scope
Protect destructive actions with short-lived confirmation tokens
Related MCP server: mysql-mcp-server
Available Tools
Tool | Description |
| List databases in the current MySQL instance |
| Create a database |
| Inspect database charset and collation settings |
| Request database deletion and return a confirmation token |
| List MySQL users |
| Create a MySQL user |
| Change a MySQL user password |
| Grant database privileges to a user |
| Revoke database privileges from a user |
| Show grants for a user |
| Request user deletion and return a confirmation token |
| Confirm and execute a destructive action token |
Safety
No raw SQL passthrough
No table, view, index, or trigger management
DROP DATABASEandDROP USERrequiremysql_confirm_taskConfirmation tokens are random, single-use, and expire quickly
Configuration
Use environment variables, matching the rest of the easy-*-mcp family.
Variable | Required | Default | Description |
| Yes | - | MySQL host name or IP address |
| No |
| MySQL port |
| Yes | - | MySQL user name |
| Yes | - | MySQL password |
| Yes | - | Default database/schema used for the admin connection |
| No |
| Maximum number of active pool connections |
| No |
| Maximum number of idle pool connections |
| No |
| Idle connection timeout in milliseconds |
| No |
| Maximum queued connection requests |
| No |
| Whether the pool waits when all connections are busy |
| No |
| Whether TCP keep-alive is enabled |
| No |
| Initial TCP keep-alive delay in milliseconds |
| No |
| Confirmation token lifetime in seconds |
Example
MYSQL_HOST=localhost
MYSQL_PORT=3306
MYSQL_USER=root
MYSQL_PASSWORD=your_password
MYSQL_DATABASE=mysql
MYSQL_ADMIN_TOKEN_TTL_SECONDS=120Claude Desktop Example
{
"mcpServers": {
"easy-mysql-admin-mcp": {
"command": "npx",
"args": ["-y", "easy-mysql-admin-mcp"],
"env": {
"MYSQL_HOST": "localhost",
"MYSQL_PORT": "3306",
"MYSQL_USER": "root",
"MYSQL_PASSWORD": "your_password",
"MYSQL_DATABASE": "mysql",
"MYSQL_ADMIN_TOKEN_TTL_SECONDS": "120"
}
}
}
}Codex config.toml Example
[mcp_servers.easy-mysql-admin-mcp]
args = ["-y", "easy-mysql-admin-mcp"]
command = "npx"
enabled = true
[mcp_servers.easy-mysql-admin-mcp.env]
MYSQL_HOST = "localhost"
MYSQL_PORT = "3306"
MYSQL_USER = "root"
MYSQL_PASSWORD = "your_password"
MYSQL_DATABASE = "mysql"
MYSQL_ADMIN_TOKEN_TTL_SECONDS = "120"OpenCode opencode.jsonc Example
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"easy-mysql-admin-mcp": {
"type": "local",
"command": ["npx", "-y", "easy-mysql-admin-mcp"],
"enabled": true,
"environment": {
"MYSQL_HOST": "localhost",
"MYSQL_PORT": "3306",
"MYSQL_USER": "root",
"MYSQL_PASSWORD": "your_password",
"MYSQL_DATABASE": "mysql",
"MYSQL_ADMIN_TOKEN_TTL_SECONDS": "120",
},
},
},
}Available Tools
12 toolsmysql_alter_user_passwordC
Change a MySQL user password.
Inputs: host (required), user (required), password (required).
mysql_confirm_taskC
Confirm and execute a previously issued destructive action token.
Inputs: token (required).
mysql_create_databaseC
Create a database.
Inputs: database (required).
mysql_create_userC
Create a MySQL user.
Inputs: host (required), user (required), password (required).
mysql_describe_databaseC
Inspect a database definition.
Inputs: database (required).
mysql_drop_databaseA
Request database deletion and return a short-lived confirmation token.
Inputs: database (required).
mysql_drop_userC
Request user deletion and return a short-lived confirmation token.
Inputs: host (required), user (required).
mysql_grant_privilegesC
Grant privileges on a database to a user.
Inputs: host (required), user (required), database (required), privileges (required), +1 more.
mysql_list_databasesA
List databases in the current MySQL instance.
Inputs: no named parameters.
mysql_list_usersA
List MySQL users.
Inputs: no named parameters.
mysql_revoke_privilegesB
Revoke privileges on a database from a user.
Inputs: host (required), user (required), database (required), privileges (required).
mysql_show_grantsC
Show grants for a user.
Inputs: host (required), user (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 12 tools
Each tool has a clearly distinct purpose—creating, listing, describing, deleting databases and users, managing privileges and passwords, and confirming destructive actions. No ambiguity.
All tools follow a consistent 'mysql_verb_noun' pattern (e.g., mysql_create_database, mysql_revoke_privileges) using snake_case throughout.
With 12 tools, the set is well-scoped for MySQL administration—covering database and user management, privileges, and password changes without being excessive.
Covers core lifecycle operations (create/read/delete) for databases and users, plus grant/revoke, password change, and a safety mechanism for drops. Missing update operations (e.g., rename database or user) but these are minor gaps.
Maintenance
Related MCP Connectors
MCP server for mandates, delegation, policy-gated execution, credential grants, and audit.
One MCP server for all your MCP servers: code mode, per-tool permissions, approvals and audit.
Hosted MySQL MCP server for Claude, ChatGPT and Cursor, with each action switched per account.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceRead-only MySQL MCP server for safe schema inspection and SELECT-style queries.11 npmMIT
- AlicenseNot gradedqualityDmaintenanceA production-ready MCP server for MySQL database operations, providing secure HTTP endpoints for read-only queries, performance analysis, and server monitoring.22MIT
- FlicenseNot gradedqualityDmaintenanceA generic MCP server for MySQL operations, enabling listing databases/tables, describing schemas, running read-only SQL, and optionally executing write SQL with logging.1-
- AlicenseAqualityDmaintenanceA read-only MySQL MCP server supporting stdio, SSE, and Streamable HTTP transports, enabling secure querying and schema inspection of MySQL databases from MCP clients.3MIT