MCP Server Mysql
MCP server by benborla Verified · npm:@zenglp
MCP server that lets Claude and other LLMs inspect MySQL schemas and run queries. Write operations are optional and off by default. It suits developers who want AI assistants to work with MySQL databases.
Install MCP Server Mysql
Built from the published package, never by AI.
claude mcp add mcp-server-mysql -- npx -y @zenglp/mcp-server-mysqlRun in your terminal. Add --scope user to use it in every project.
{
"mcpServers": {
"mcp-server-mysql": {
"args": [
"-y",
"@zenglp/mcp-server-mysql"
],
"command": "npx"
}
}
}Settings, Developer, Edit config. Paste into claude_desktop_config.json and restart.
{
"mcpServers": {
"mcp-server-mysql": {
"args": [
"-y",
"@zenglp/mcp-server-mysql"
],
"command": "npx"
}
}
}Add to ~/.cursor/mcp.json (all projects) or .cursor/mcp.json (this project).
{
"servers": {
"mcp-server-mysql": {
"args": [
"-y",
"@zenglp/mcp-server-mysql"
],
"command": "npx"
}
}
}Add to .vscode/mcp.json. VS Code uses "servers", not "mcpServers".
codex mcp add mcp-server-mysql -- npx -y @zenglp/mcp-server-mysql{
"mcpServers": {
"mcp-server-mysql": {
"args": [
"-y",
"@zenglp/mcp-server-mysql"
],
"command": "npx"
}
}
}Add to ~/.gemini/config/mcp_config.json (all projects) or .agents/mcp_config.json (this project).
gemini mcp add mcp-server-mysql npx -y @zenglp/mcp-server-mysqlGemini CLI was replaced by Antigravity CLI in June 2026 and remains only for enterprise licences and paid API keys.
MCP servers run with your permissions and can read what you give them access to. Some need an API key: check the README and add it under env in the mcp-server-mysql block.
About
MCP Server for MySQL gives Claude and other LLMs access to MySQL through the Model Context Protocol. The assistant can inspect schemas, run SQL queries, and, if enabled, write data. It exposes a mysql_query tool and a mysql://tables resource that lists tables and column metadata for the connected database.
All write operations are disabled by default. Insert, update and delete can each be enabled with an environment flag. The server also offers SSH tunnel support, multi-DB mode, schema-specific permissions, PII redaction, remote mode over HTTP with bearer token auth, and SSL/TLS with an mTLS option. It is installed with npx and configured through environment variables. It is aimed at developers who use Claude Code or Claude Desktop.
Written from the project's README and checked against it.
Tools it gives your assistant
mysql_queryExecutes SQL queries. Read-only by default, with write operations enabled per flag.mysql://tablesLists all tables and column metadata for the connected database.
What you need
- Node.js v20+
- MySQL 5.7+ (8.0+ recommended)
- MySQL user with appropriate privileges
Try asking
- Show me the tables and columns in my connected MySQL database.
- Run a query that counts orders per customer for last month.
- Check the schema of the users table before writing a report query.
Good to know
- Read-only by default. Write operations need ALLOW_INSERT_OPERATION, ALLOW_UPDATE_OPERATION or ALLOW_DELETE_OPERATION set to true.
- Requires Node.js v20 or later and MySQL 5.7 or later.
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: README.md, package.json. This looks for known risky patterns and is not a full audit. How grades work
Alternatives to MCP Server Mysql
All alternatives →Connects Supabase projects to AI assistants such as Cursor, Claude and Windsurf over the Model Context Protocol. It lets assistants manage tables, fetch config and query data in a Supabase project.
ArcadeDB MCP Server is the built-in Model Context Protocol server of the ArcadeDB multi-model database. It lets AI assistants and LLMs work with ArcadeDB's graph, document, time-series, vector and other data models. It suits people who already run ArcadeDB and want assistant access to it.
Connects MCP clients such as Claude Desktop, Cursor and VS Code to PostgreSQL, MySQL, MariaDB, SQL Server, Oracle, ClickHouse and SQLite. It exposes two tools by default, with read-only mode and query timeouts available as guardrails.
MCP Toolbox for Databases is an open source MCP server that connects AI agents, IDEs and applications to enterprise databases. It provides prebuilt tools for exploring schemas and running queries, plus a framework for custom tools. It is aimed at developers building agents that need database access.
Connects AI agents, IDEs and applications to enterprise databases through the Model Context Protocol. Offers prebuilt database tools for MCP clients and a framework for building custom tools for production agents.
MongoDB MCP Server lets AI assistants interact with MongoDB databases and MongoDB Atlas. It is an official server from mongodb-js, run locally with npx or Docker. It works with self-managed deployments and Atlas clusters.
Compare with Supabase, ArcadeDB MCP Server or DBHub
MCP Server Mysql: common questions
Can the AI change data in my MySQL database?
Not by default. All write operations are disabled until you enable the insert, update or delete flags.
Does it work with remote databases?
Yes. The server has built-in SSH tunnel support for remote databases, and a remote mode that uses HTTP transport with bearer token auth.
Which MySQL versions are supported?
The source lists MySQL 5.7 or later, with 8.0 or later recommended.
How do I install MCP Server Mysql?
In Claude Code run claude mcp add mcp-server-mysql -- npx -y @zenglp/mcp-server-mysql. For Claude Desktop, Cursor and VS Code, paste the config shown above and restart. See the install guides.
Is MCP Server Mysql the official server?
MCP Server Mysql is published by npm:@zenglp from its verified domain in the official MCP Registry.
Is MCP Server Mysql free?
The code is published under the MIT licence. The service it connects to may have its own pricing.
Is MCP Server Mysql safe to use?
It scores 80 of 100. Grades: maintenance C, licence A, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to MCP Server Mysql?
Similar MCP servers: Supabase, ArcadeDB MCP Server, DBHub, MCP Toolbox for Databases.
Does MCP Server Mysql work with ChatGPT?
Not directly. It runs locally, and ChatGPT only connects to remote servers with a URL. Use it in Claude Code, Claude Desktop, Cursor, VS Code or Codex.
