# AdoMcp

> AdoMcp is an open-source MCP server for databases. Let agents explore database schemas and comments and run read-only SQL, with opt-in writes. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, self-hosted
- **Repository:** https://github.com/john0king/adomcp
- **MCP Registry name:** io.github.John0King/adomcp
- **Categories:** [databases](https://ai-powered.com/categories/databases), [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-11-18

## About

AdoMcp is a database server built on ADO.NET that lets an agent understand a database before touching it. It finds tables, views, procedures, functions, triggers, sequences and synonyms, reads columns with types, nullability, keys, defaults and the comments people wrote on them, and lists indexes. SQL Server, MySQL and MariaDB, PostgreSQL, SQLite and Oracle are supported.

Safety is deliberate. Reads go through a tool that accepts a single SELECT or WITH query and returns CSV, using a conservative lexical filter that blocks writes, DDL, procedure calls, SELECT INTO and multi-statement batches. The README concedes this is not a full SQL parser and cannot see side effects inside database functions. A separate write tool is disabled by default and enabled per connection or globally at startup, and the server's instructions tell the client to use it only with explicit authorisation.

Connections come from a config file, environment variables or User Secrets, or the agent can add one for the session. It runs over stdio or HTTP, needs .NET 10, and ships as a NuGet package and plugin for Codex, Claude Code and GitHub Copilot.

## Features

- **Schema discovery:** Find tables, views, procedures, triggers, sequences and synonyms.
- **Comments included:** Reads table and column descriptions where the database supports them.
- **Index inspection:** Lists a table's indexes.
- **Read-only query guard:** Allows only single SELECT or WITH statements and returns CSV.
- **Opt-in writes:** The write tool is off unless enabled.
- **Five databases:** Works with SQL Server, MySQL, MariaDB, PostgreSQL, SQLite and Oracle.

## Good for

- Let an agent learn an unfamiliar schema before writing queries
- Check indexes while tuning a slow query
- Run safe read-only analysis on a development database
- Resolve Oracle synonyms to real schemas

## Install

### Claude Code (Terminal)

```sh
claude mcp add adomcp -- dnx adomcp --yes
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "adomcp": {
      "command": "dnx",
      "args": [
        "adomcp",
        "--yes"
      ]
    }
  }
}
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "adomcp": {
      "command": "dnx",
      "args": [
        "adomcp",
        "--yes"
      ]
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "adomcp": {
      "type": "stdio",
      "command": "dnx",
      "args": [
        "adomcp",
        "--yes"
      ]
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "adomcp": {
      "command": "dnx",
      "args": [
        "adomcp",
        "--yes"
      ]
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "adomcp": {
      "command": "dnx",
      "args": [
        "adomcp",
        "--yes"
      ]
    }
  }
}
```

## Tools

- `list_connections`: List configured database connections
- `add_connection`: Add or replace a connection in the current process
- `remove_connection`: Remove a runtime connection
- `list_objects`: Find tables, views, procedures, functions and other objects
- `get_table_schema`: Columns, types, keys, defaults and comments
- `get_table_indexes`: A table's indexes
- `query_sql`: Run read-only SQL and return CSV
- `execute_sql`: Run write SQL when enabled

## FAQ

### Can it modify my data?

Only if you enable the write option, which is off by default.

### What do I need to run it?

The .NET 10 SDK; dnx -y AdoMcp fetches it from NuGet.

### Which databases work?

SQL Server, MySQL, MariaDB, PostgreSQL, SQLite and Oracle.

### Is the read guard perfect?

No, the README says it is a conservative lexical filter and cannot see side effects inside functions.

### Is AdoMcp free?

Yes. AdoMcp is open source, so you can use and self-host it for free.

### How do I add AdoMcp to Claude Code?

Run this command in your terminal: claude mcp add adomcp -- dnx adomcp --yes

### What are the best alternatives to AdoMcp?

The closest alternatives to AdoMcp are REA, Context7, Chrome DevTools MCP, Codebase Memory and GitHub.

## Where this comes from

- Description: written from the project's README.
- Install steps: from the official MCP Registry entry.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [Context7](https://ai-powered.com/mcp/context7): Context7 is a freemium MCP server for developer tools.
- [Chrome DevTools MCP](https://ai-powered.com/mcp/chrome-devtools-mcp-2): Chrome DevTools MCP is an open-source MCP server for browser automation.
- [Codebase Memory](https://ai-powered.com/mcp/codebase-memory): Codebase Memory is an open-source MCP server for knowledge and memory.
- [GitHub](https://ai-powered.com/mcp/github-2): GitHub is an open-source MCP server for developer tools.
- [Serena MCP: the IDE for your agent](https://ai-powered.com/mcp/serena-mcp-the-ide-for-your-agent): Serena MCP: the IDE for your agent is an open-source MCP server for developer tools.
- [awesome-mcp-servers](https://ai-powered.com/mcp/awesome-mcp-servers-2): awesome-mcp-servers is an open-source MCP server for developer tools.
- [XERJ](https://ai-powered.com/mcp/xerj): XERJ is an open-source MCP server for knowledge and memory.

---
Source: https://ai-powered.com/mcp/adomcp
