Sponsored byOutsenseAI that finds your next clients
SponsorGROUOutbound, LinkedIn content and leads for B2B teamsSponsorOutsenseAI that finds your next clientsAd+Your tool hereSeen by people installing AI tools@Weekly picksThe best new tools, one email a week

Mysql MCP server

MCP server by mukul975 Verified · gh:mukul975

MCP MySQL Server is a Model Context Protocol server for MySQL databases. It offers tools for running queries, checking server status, and diagnosing performance, deadlocks, replication lag and user privileges.

  • Score 70
  • 22 stars
  • MIT
  • Updated

Install Mysql MCP server

Built from the published package, never by AI.

claude mcp add mysql-mcp-server -- npx -y mcp-mysql-server

Run in your terminal. Add --scope user to use it in every project.

Step-by-step: install Mysql MCP server in Claude Code

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 mysql-mcp-server block.

About

MCP MySQL Server is a Model Context Protocol server for MySQL databases. Its README describes HTTP endpoints for executing read-only queries, analyzing database performance, and monitoring MySQL server status. It also lists diagnostic, operational and security tools, such as slow query analysis, deadlock detection, privilege auditing and replication lag monitoring.

The server runs over stdio by default and can use SSE for web clients. It reads MySQL connection settings from environment variables. The source describes Docker and local installation, and optional bearer token or API key authentication with rate limiting for the HTTP server. It suits people who want an AI assistant to inspect and diagnose MySQL databases.

Written from the project's README and checked against it.

Tools it gives your assistant

  • mysql_queryExecutes read-only SQL queries and returns columns, rows and row count.
  • mysql_statusGets MySQL server status variables.
  • mysql_innodb_metricsAnalyzes InnoDB performance metrics.
  • pingHealth check utility that returns an echo and timestamp.
  • list_mysql_tablesLists tables in the MySQL database.
  • mysql_slow_query_analysisAnalyzes slow queries.
  • mysql_deadlock_detectionDetects deadlocks.
  • mysql_user_privilegesAudits user privileges.
  • mysql_replication_lag_monitoringMonitors replication lag.
  • mysql_ssl_tls_configuration_auditAudits SSL/TLS configuration.

What you need

  • Python
  • A reachable MySQL server
  • Docker or Docker Compose (optional)

Try asking

  • Run a read-only query to count the rows in my users table.
  • Analyze slow queries on my MySQL server and suggest fixes.
  • Check user privileges and SSL/TLS configuration for my MySQL server.

Good to know

  • The README describes the core query tool as read-only.
  • The README also lists execute_sql and user management tools, which can modify data.
  • The README says to use the server only in trusted environments or behind network security.
  • The README does not give a total tool count.

Security check

A

No 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 Mysql MCP server

All alternatives →
Supabase supabase
97

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.

AAA Local and remote 172k/wk
ArcadeDB MCP Server ArcadeData
94

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.

AAA Local 1.3k
DBHubbytebase
94

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.

AAA Local 343k/wk
MCP Toolbox for Databasesgoogleapis
94

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.

AAA Local 17k
MCP Toolbox for Databasesgoogleapis
94

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.

AAA Local 17k
mongodb-mcp-servermongodb-js
94

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.

AAA Local 203k/wk

Compare with Supabase, ArcadeDB MCP Server or DBHub

Mysql MCP server: common questions

Is MCP MySQL Server read-only?

The README says the HTTP query endpoint executes read-only queries and prevents data modification. It also lists execute_sql and user management tools, which can change data.

How does it connect to MySQL?

It reads MYSQL_HOST, MYSQL_PORT, MYSQL_USER, MYSQL_PASSWORD and MYSQL_DATABASE from environment variables.

What transports does it support?

The README says it uses stdio by default and SSE for web clients when started with the transport flag.

How do I install Mysql MCP server?

In Claude Code run claude mcp add mysql-mcp-server -- npx -y mcp-mysql-server. For Claude Desktop, Cursor and VS Code, paste the config shown above and restart. See the install guides.

Is Mysql MCP server the official server?

Mysql MCP server is published by gh:mukul975 from its verified domain in the official MCP Registry.

Is Mysql MCP server free?

The code is published under the MIT licence. The service it connects to may have its own pricing.

Is Mysql MCP server safe to use?

It scores 70 of 100. Grades: maintenance A, licence A, quality C. 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 Mysql MCP server?

Similar MCP servers: Supabase, ArcadeDB MCP Server, DBHub, MCP Toolbox for Databases.

Does Mysql MCP server 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.

Mysql MCP server Install

Add to stack

Loading.