The full upstream README, mirrored here for reference. Install config, tool schemas, adoption signals, and an original overview live on the Raw SQL MCP listing page.
Raw SQL MCP is a STDIO MCP server for executing raw SQL against SQL Server, SQLite, PostgreSQL, MySQL, and MariaDB.
[!IMPORTANT] Use it carefully. The server does not protect you from destructive queries, expensive queries, SQL injection, missing pagination, or unsafe data exposure. Always review and approve queries before running them.

Run the server with dnx:
For a specific version:
Package: RawSqlMcp on NuGet
Databases are configured with environment variables under RawSqlMcp__Databases__.
SQLite:
PostgreSQL:
MySQL/MariaDB:
SQL Server:
Optional command timeout, in seconds:
[!INFO] The legacy
RawSqlMcp__ConnectionStrings__Default="..."format is obsolete. It still works for compatibility and is interpreted as SQL Server.
Register the server in an MCP client as a STDIO server:
The server exposes tools for listing configured database names, reading schema metadata, and executing raw, parameterized, and scalar SQL queries.
