MCP-Mirror

MCP Server for MySQL based on NodeJS

Community MCP-Mirror
Updated

MCP server for interacting with MySQL databases based on Node

MCP Server for MySQL based on NodeJS

smithery badgeDemo

A Model Context Protocol server that provides read-only access to MySQL databases. This server enables LLMs to inspect database schemas and execute read-only queries.

Components

Tools

  • mysql_query
    • Execute read-only SQL queries against the connected database
    • Input: sql (string): The SQL query to execute
    • All queries are executed within a READ ONLY transaction

Resources

The server provides schema information for each table in the database:

  • Table Schemas
    • JSON schema information for each table
    • Includes column names and data types
    • Automatically discovered from database metadata

Usage with Claude Desktop

To use this server with the Claude Desktop app, add the following configuration to the "mcpServers" section of your claude_desktop_config.json:

{
  "mcpServers": {
    "mcp_server_myqsl": {
      "command": "npx",
      "args": [
        "-y",
        "@benborla29/mcp-server-mysql",
      ],
      "env": {
        "MYSQL_HOST": "127.0.0.1",
        "MYSQL_PORT": "3306",
        "MYSQL_USER": "root",
        "MYSQL_PASS": "",
        "MYSQL_DB": "db_name"
      }

    }
  }
}

Replace /db_name with your database name or leave it blank to retrieve all databases.

Troubleshooting

If you encounter an error "Could not connect to MCP server mcp-server-mysql", you may need to explicitlyset the path of all required binaries such as the configuration below:

{
  "mcpServers": {
    "mcp_server_myqsl": {
      "command": "/path/to/npx/binary/npx",
      "args": [
        "-y",
        "@benborla29/mcp-server-mysql",
      ],
      "env": {
        "MYSQL_HOST": "127.0.0.1",
        "MYSQL_PORT": "3306",
        "MYSQL_USER": "root",
        "MYSQL_PASS": "",
        "MYSQL_DB": "db_name"
        "PATH": "/path/to/node/bin:/usr/bin:/bin" <-- Add this
      }

    }
  }
}

License

This MCP server is licensed under the MIT License. This means you are free to use, modify, and distribute the software, subject to the terms and conditions of the MIT License. For more details, please see the LICENSE file in the project repository.

MCP Server ยท Populars

MCP Server ยท New

    voygr-tech

    PlaceCall โ˜Ž๏ธ

    The phone is your last API. Give your agent a voice to call any US business - reservations, inquiries, quotes. Verified outcome + transcript. First 250 calls free.

    Community voygr-tech
    colibird-ai

    LMCP โ€” Context and Actions for Your AI

    192+ local tools for Claude, ChatGPT, Cursor & Grok โ€” Mail, iMessage, Teams, Slack, WhatsApp, OneDrive, Google Drive, Zoom, Outlook, Office. Native macOS and Windows, runs on your computer, no API keys.

    Community colibird-ai
    HoldMyBeer-gg

    blenderwright

    MCP server for Blender. 191 tools for modelling, materials, rendering and more, driven by Claude, Cursor, Codex, Ollama, llama.cpp, or any MCP client.

    Community HoldMyBeer-gg
    tesseron-dev

    tesseron

    Tesseron protocol, documentation, MCP gateway and Claude Code plugin. Created and maintained by Eigenwise.

    Community tesseron-dev
    getsentry

    sentry-mcp

    An MCP server for interacting with Sentry via LLMs.

    Community getsentry