mariadb-mcp-server
An mcp server that provides read-only access to MariaDB.
Overview
mariadb-mcp-server is an MCP server implementation that provides read-only access to MariaDB, allowing users to retrieve data efficiently.
To use mariadb-mcp-server, set up the database connection environment variables and configure the server according to your system's requirements. Then, run the server using the specified command.
- Exposes schema list in the database. - Executes read-only operations against MariaDB. - Supports configuration through environment variables.
- Accessing database schemas for documentation purposes.
- Running read-only queries for data analysis.
- Integrating with applications that require database access without modification capabilities.
Add to your AI client
Use these steps to connect mariadb-mcp-server in Cursor, Claude, VS Code, and other MCP-compatible apps. The same JSON appears in the Use with menu above for one-click copy.
Cursor
Add this to your .cursor/mcp.json file in your project root, then restart Cursor.
.cursor/mcp.json
{
"mcpServers": {
"mariadb-mcp-server-abel9851": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-mariadb-mcp-server-abel9851"
]
}
}
}Claude Desktop
Add this server entry to the mcpServers object in your Claude Desktop config, then restart the app.
~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows)
{
"mcpServers": {
"mariadb-mcp-server-abel9851": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-mariadb-mcp-server-abel9851"
]
}
}
}Claude Code
Add this to your project's .mcp.json file. Claude Code will detect it automatically.
.mcp.json (project root)
{
"mcpServers": {
"mariadb-mcp-server-abel9851": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-mariadb-mcp-server-abel9851"
]
}
}
}VS Code (Copilot)
Add this to your .vscode/mcp.json file. Requires the GitHub Copilot extension with MCP support enabled.
.vscode/mcp.json
{
"servers": {
"mariadb-mcp-server-abel9851": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-mariadb-mcp-server-abel9851"
]
}
}
}Windsurf
Add this to your Windsurf MCP config file, then restart Windsurf.
~/.codeium/windsurf/mcp_config.json
{
"mcpServers": {
"mariadb-mcp-server-abel9851": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-mariadb-mcp-server-abel9851"
]
}
}
}Cline
Open Cline settings, navigate to MCP Servers, and add this server configuration.
Cline MCP Settings (via UI)
{
"mcpServers": {
"mariadb-mcp-server-abel9851": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-mariadb-mcp-server-abel9851"
]
}
}
}FAQ
What is the purpose of mariadb-mcp-server?
It provides a way to access MariaDB data in a read-only manner, ensuring data integrity.
How do I install the required dependencies?
You can install the MariaDB Connector/C using Homebrew on macOS with the command: `brew install mariadb-connector-c`.
Can I modify the data using this server?
No, mariadb-mcp-server is designed for read-only access only.