xamp
Provides tools to list databases, list tables, describe tables, and run read/write queries against MariaDB databases (via XAMPP or custom credentials).
Enables querying MySQL databases with tools for listing databases, tables, describe table, read query, and write query (when enabled).
Allows interaction with XAMPP's MariaDB/MySQL databases, providing tools for listing databases, tables, describing tables, and executing read/write queries.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@xampList all databases on my XAMPP server."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP-XAMP
MCP server that gives Claude Code and OpenCode direct access to your XAMPP MariaDB/MySQL databases. Five tools: list databases, list tables, describe table, read query, write query.
Quick Start
Clone the repo
Configure your AI agent (Claude Code or OpenCode)
Start querying —
list_databases,read_query, etc.
No global install needed — runs directly with uv run.
Related MCP server: MariaDB MCP Server
Requirements
Python 3.13+
XAMPP with MariaDB/MySQL running on
localhost:3306
Installation
git clone https://github.com/<user>/mcp-xamp.git
cd mcp-xamp
uv syncVerify it works:
uv run mcp-xampOptional: install globally
If you prefer mcp-xamp available as a command anywhere:
uv tool install --python 3.13 .Then use "command": "mcp-xamp" instead of uv run --directory ... in the
configs below.
Claude Code Setup
One-command setup
claude mcp add --transport stdio --scope project \
--env MCP_XAMP_ALLOW_WRITE=true \
xamp -- uv run --directory /path/to/mcp-xamp mcp-xampReplace /path/to/mcp-xamp with the actual path where you cloned the repo.
This creates a .mcp.json in your project root that your whole team can share
via git (each member adjusts the path).
Manual config
Add this to your ~/.claude.json (user scope) or .mcp.json (project scope):
{
"mcpServers": {
"xamp": {
"command": "uv",
"args": [
"run",
"--directory",
"/path/to/mcp-xamp",
"mcp-xamp"
],
"env": {
"MCP_XAMP_ALLOW_WRITE": "true"
}
}
}
}If you used uv tool install, the config is simpler:
{
"mcpServers": {
"xamp": {
"command": "mcp-xamp",
"args": [],
"env": {
"MCP_XAMP_ALLOW_WRITE": "true"
}
}
}
}Custom credentials
If your XAMPP uses non-default credentials:
claude mcp add --transport stdio --scope project \
--env MCP_XAMP_HOST=db.example.com \
--env MCP_XAMP_PORT=3307 \
--env MCP_XAMP_USER=agent \
--env MCP_XAMP_PASSWORD=s3cret \
--env MCP_XAMP_ALLOW_WRITE=true \
xamp -- uv run --directory /path/to/mcp-xamp mcp-xampVerify
Inside Claude Code, run /mcp to confirm xamp is connected. Then try:
List all databases on my XAMPP server.OpenCode Setup
Config location
OpenCode reads MCP config from opencode.json or opencode.jsonc. The file
can be in:
Location | Scope |
| Project-specific |
| Project-specific (alt) |
| Global (all projects) |
Add the MCP server
Add this block to your opencode.json or opencode.jsonc:
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"xamp": {
"type": "local",
"command": ["uv", "run", "--directory", "/path/to/mcp-xamp", "mcp-xamp"],
"enabled": true,
"environment": {
"MCP_XAMP_ALLOW_WRITE": "true"
}
}
}
}Replace /path/to/mcp-xamp with your actual clone path.
If you used uv tool install, simplify to:
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"xamp": {
"type": "local",
"command": ["mcp-xamp"],
"enabled": true,
"environment": {
"MCP_XAMP_ALLOW_WRITE": "true"
}
}
}
}Verify
Restart OpenCode, then try:
Show me all databases on the xamp server. use xamp toolsEnvironment Variables
All configuration goes through environment variables. Sensible defaults for a standard XAMPP installation.
Variable | Default | Description |
|
| MariaDB/MySQL host |
|
| MariaDB/MySQL port |
|
| Database user |
| (empty) | Database password |
|
| Set to |
Credentials are read from environment variables only. They never appear in tool arguments, log output, or error messages.
Tools
Tool | Description | Requires |
| Show all accessible databases | — |
| Show tables in a database |
|
| Show columns, types, and keys |
|
| Execute SELECT / SHOW / DESCRIBE / EXPLAIN |
|
| Execute INSERT / UPDATE / DELETE / DDL |
|
Security
Read-only by default. Write operations require
MCP_XAMP_ALLOW_WRITE=true.Credentials never logged. Host, port, user, and password are stripped from error messages.
Credentials only from env vars. No tool parameters, no config files, no CLI args.
Connection-per-query. Each tool invocation opens and closes its own connection — no shared state, no stale connections.
XAMPP default is root with no password. Create a dedicated user for production use:
CREATE USER 'mcp_agent'@'127.0.0.1' IDENTIFIED BY 'secure_password'; GRANT SELECT ON *.* TO 'mcp_agent'@'127.0.0.1';
Development
# Install dev dependencies
uv sync --group dev
# Run tests
uv run pytest -v --cov=src/mcp_xamp
# Lint
uv run ruff check src/ tests/
# Format
uv run ruff format src/ tests/License
MIT — see LICENSE.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/yeyorg/mcp-xamp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server