About MySQL MCP Server
MySQL MCP Server exposes MySQL database metadata and read-only querying through a standardized interface. It is intended for AI models and MCP clients that need to inspect tables and run safe queries.
Key features
- 01List database tables
- 02Retrieve table schemas
- 03Run read-only SQL queries
- 04Automatic rollback for transactions
Use cases
- 01Inspect available database tables
- 02Check a table's schema
- 03Run read-only queries against MySQL
MCP support
It exposes table listing, schema retrieval, and read-only SQL query capabilities to MCP clients. Transaction handling includes automatic rollback.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
We haven’t collected a package or remote endpoint for this server. Follow the instructions in the project README.
Tools
Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.
Details
From the project READMEMySQL MCP Server
A MySQL implementation of the Model Context Protocol (MCP) server. This server allows AI models to interact with MySQL databases through a standardized interface.
Features
- List available database tables
- Get table schemas
- Execute read-only SQL queries
- Safe transaction handling with automatic rollback
Installation
npm install
npm run build
Usage
Claude Desktop App
code ~/Library/Application\ Support/Claude/claude_desktop_config.json
{
"mcpServers": {
"mysql": {
"command": "node",
"args": [
"/ABSOLUTE/PATH/TO/PARENT/FOLDER/mysql-mcp-server/dist/index.js",
],
"env": {
"MYSQL_HOST": "127.0.0.1",
"MYSQL_PORT": "3306",
"MYSQL_USER": "root",
"MYSQL_PASSWORD": "",
"MYSQL_DATABASE": "test"
}
}
}
}
Replace the env config with yours!
License
MIT
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.