MySQL Database Server
MySQL MCP server for cursor
Installation
Installing for Claude Desktop
Option 1: One-Command Installation
npx mcpbar@latest install vitalyDV/mysql-mcp -c claudeThis command will automatically install and configure the MySQL Database Server MCP server for your selected client.
Option 2: Manual Configuration
Run the command below to open your configuration file:
npx mcpbar@latest edit -c claudeAfter opening your configuration file, copy and paste this configuration:
View JSON configuration
{
"mcpServers": {
"MySQL Database Server": {
"command": "npx",
"args": [
"-y",
"mysql-mcp"
],
"env": {
"MYSQL_HOST": "${input:mysql_host}",
"MYSQL_PORT": "${input:mysql_port}",
"MYSQL_USER": "${input:mysql_user}",
"MYSQL_PASS": "${input:mysql_pass}",
"MYSQL_DB": "${input:mysql_db}"
}
}
}
}MySQL MCP Server
This project implements an MCP (Model Context Protocol) server for working with MySQL database.
Repository
This project is available on GitHub: https://github.com/vitalyDV/mysql-mcp
Clone the repository
git clone https://github.com/vitalyDV/mysql-mcp.git
cd mysql-mcp
npm install
add config to mcp.json
{
"mcpServers": {
"mysql_mcp_readonly": {
"command": "node",
"args": [
"./mysql-mcp/index.js"
],
"env": {
"MYSQL_HOST": "127.0.0.1",
"MYSQL_PORT": "3306",
"MYSQL_USER": "root",
"MYSQL_PASS": "",
"MYSQL_DB": "db",
}
}
}
}
Environment Variables
MYSQL_HOST- MySQL server hostMYSQL_PORT- MySQL server portMYSQL_USER- MySQL usernameMYSQL_PASS- MySQL passwordMYSQL_DB- MySQL database name
Available MCP tools
query- execute SQL queries (only SELECT, SHOW, EXPLAIN, DESCRIBE)table-schema- get table structurelist-tables- get list of all tables in the database
Available MCP resources
table://{name}- get data from the specified table (up to 100 rows)
Details:
Stars
2Forks
1Last commit
7 months agoRepository age
7 months
Auto-fetched from GitHub .
MCP servers similar to MySQL Database Server:
Stars
Forks
Last commit
Stars
Forks
Last commit
Stars
Forks
Last commit