MySQL MCP Server
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
🐬 MySQL MCP Server (FastMCP-Powered)
Leverage the power of AI to automate your MySQL workflows with FastMCP.
This tool enables AI agents like Claude, OpenAI, or DeepSeek to interact with your MySQL database using natural language, making database management seamless and intelligent.
Whether you're generating synthetic data, querying your tables, or performing updates, this MCP server allows AI to operate on your database through standardized interfaces — all from your local machine.
🔎 Best use for generating synthetic data for testing your apis.
Related MCP server: MySQL MCP Server
💡 Key Features
Automates SQL tasks via AI (Claude, OpenAI, DeepSeek, etc.)
Works over Stdio, ideal for local desktop integration
Generates synthetic data based on your schema and recent values
No manual SQL knowledge required
Highly useful for test environments and data prototyping
🛠️ Supported Tools
Tool | Description |
| Retrieve all column names of a table |
| List all table names in the database |
| Fetch records from any table |
| Insert data into a table |
| Update records with conditions |
| Delete records based on criteria |
These are internally used by the AI to understand and manipulate your database efficiently.
⚙️ Configuration & Setup
📋 Prerequisites
Python 3.10+
MySQL (running locally or remotely)
Anthropic Claude Desktop app (or Cursor)
UV (Python package manager), install with
curl -LsSf https://astral.sh/uv/install.sh | sh
Steps
Clone this repository
git clone https://github.com/Ashutosh-rajput/mysql-mcp.git cd mysql-mcp uv pip install -r requirements.txtFill the .env
MYSQL_HOST=localhost MYSQL_PORT=3306 MYSQL_USER=root MYSQL_PASSWORD=yourpassword MYSQL_DATABASE=yourdatabaseConnect to the MCP server
Copy the below json with the appropriate {{PATH}} values:
{ "mcpServers": { "Mysql": { "command": "[path to uv]/uv", "args": [ "run", "--with", "fastmcp", "--with", "mysql-connector-python", "--with", "python-dotenv", "fastmcp", "run", "[path to your main.py]/main.py" ] } } }For Claude, save this as
claude_desktop_config.jsonin your Claude Desktop configuration directory at:~/Library/Application Support/Claude/claude_desktop_config.jsonFor Cursor, save this as
mcp.jsonin your Cursor configuration directory at:~/.cursor/mcp.jsonRestart Claude Desktop / Cursor
Open Claude Desktop and you should now see WhatsApp as an available integration.
Or restart Cursor.
🧠 Tip
Use this project as a backbone to build intelligent, event-driven Mysql bots, agents.
📜 License
MIT License. Feel free to use and modify as per your needs.
👤 Author: Ashutosh Rajput
🌐 Project: MySql-MCP
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Work with your database from AI tools: ask, export, approved changes, and scheduled jobs.
Store, query, and update structured data from any AI agent
Query, explore, and manage your databases through natural conversation.
Query Postgres, MySQL, SQL Server, Oracle, BigQuery, ClickHouse and Redshift from your AI client.
Related MCP Servers
- AlicenseBqualityDmaintenanceEnables AI assistants to manage MySQL databases through natural language commands. Supports database operations, table management, data queries, and import/export functionality with built-in security features.1517 npm1MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to securely connect to and manage MySQL databases with support for multiple database connections, complete CRUD operations, schema inspection, and dynamic connection management through natural language.19 npm81MIT
- AlicenseAqualityDmaintenanceEnables AI agents to safely interact with MySQL/MariaDB databases, supporting read-only queries by default with optional write operations and access control.8MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to directly query MySQL databases, list tables, and view table structures through natural language.30 npmMIT