Skip to content
appsgit

MCP Server MySQL

MCP Server MySQL is an MCP server that provides read-only access to MySQL databases. It has 2,166 GitHub stars, is released under the MIT license and runs locally with npx -y @benborla29/mcp-server-mysql. It works with Claude Desktop, Claude Code, Cursor and VS Code.

github.com/benborla/mcp-server-mysql (opens in a new tab)

Data as of from the GitHub API; description from the project's repository. Report an error

Install MCP Server MySQL

Generated from the server's published package. Replace your-value with your own values.

Claude Desktop

claude_desktop_config.json
{
  "mcpServers": {
    "mcp-server-mysql": {
      "command": "npx",
      "args": [
        "-y",
        "@benborla29/mcp-server-mysql"
      ],
      "env": {
        "MYSQL_HOST": "your-value",
        "MYSQL_PORT": "your-value",
        "MYSQL_USER": "your-value",
        "MYSQL_PASS": "your-value",
        "MYSQL_DB": "your-value"
      }
    }
  }
}

Settings > Developer > Edit Config. macOS: ~/Library/Application Support/Claude/, Windows: %APPDATA%\Claude\. Restart Claude Desktop afterwards.

Claude Code

claude mcp add --env MYSQL_HOST=your-value --env MYSQL_PORT=your-value --env MYSQL_USER=your-value --env MYSQL_PASS=your-value --env MYSQL_DB=your-value --transport stdio mcp-server-mysql -- npx -y @benborla29/mcp-server-mysql

Cursor

.cursor/mcp.json
{
  "mcpServers": {
    "mcp-server-mysql": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@benborla29/mcp-server-mysql"
      ],
      "env": {
        "MYSQL_HOST": "your-value",
        "MYSQL_PORT": "your-value",
        "MYSQL_USER": "your-value",
        "MYSQL_PASS": "your-value",
        "MYSQL_DB": "your-value"
      }
    }
  }
}

Project file; use ~/.cursor/mcp.json to enable it in every project.

VS Code

.vscode/mcp.json
{
  "servers": {
    "mcp-server-mysql": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@benborla29/mcp-server-mysql"
      ],
      "env": {
        "MYSQL_HOST": "your-value",
        "MYSQL_PORT": "your-value",
        "MYSQL_USER": "your-value",
        "MYSQL_PASS": "your-value",
        "MYSQL_DB": "your-value"
      }
    }
  }
}

Config formats checked against the official docs on Oct 7, 2026: modelcontextprotocol.io (opens in a new tab), code.claude.com (opens in a new tab), cursor.com (opens in a new tab), code.visualstudio.com (opens in a new tab).

Environment variables

Variables the server reads at startup.

NameRequiredDescription
MYSQL_HOSTNoShown in the README's example configuration.
MYSQL_PORTNoShown in the README's example configuration.
MYSQL_USERNoShown in the README's example configuration.
MYSQL_PASSNoShown in the README's example configuration.
MYSQL_DBNoShown in the README's example configuration.

About MCP Server MySQL

Using mcp-server-mysql to let your AI query MySQL? Bloome brings that to your whole team — an AI-agent IM platform where AI agents are members of the chat. Connect your MCP tools and have agents inspect schemas, run queries, and answer data questions for everyone in one thread. Zero local setup, runs in the cloud, on web and mobile.

FAQ

MCP Server MySQL FAQ

Still curious? Email info@appsgit.com.

How do I install the MCP Server MySQL MCP server?

Add the command npx -y @benborla29/mcp-server-mysql to your MCP client: put it in claude_desktop_config.json for Claude Desktop, run claude mcp add for Claude Code, or add it to .cursor/mcp.json (Cursor) or .vscode/mcp.json (VS Code). The snippets on this page are ready to paste.

Is MCP Server MySQL free?

The server is open source under the MIT license, so running it is free. It does not declare any required API key.

Is MCP Server MySQL actively maintained?

The most recent commit was on Jul 27, 2026. The latest release is v2.0.9, published Jun 19, 2026. appsgit only lists MCP servers with a commit in the last six months.