SQL MCP Server
by abhishekkumar2021io.github.Abhishekkumar2021/sqlv0.1.0
MCP server for SQL databases — read-only querying and schema introspection over Postgres and SQLite, with a gated write mode, from any MCP client.
context tax
queued
security
queued
cold start
queued
freshness
Slowing3mo ago
Install SQL MCP server
Install in Claude Code
claude mcp add sql -e DB_CONN_default='<db-conn-default>' -- npx -y @abhishekmcp/sqlInstall in Cursor
{
"mcpServers": {
"sql": {
"command": "npx",
"args": [
"-y",
"@abhishekmcp/sql"
],
"env": {
"DB_CONN_default": "<db-conn-default>"
}
}
}
}Add to ~/.cursor/mcp.json (global) or .cursor/mcp.json (project).
Install in Claude Desktop
{
"mcpServers": {
"sql": {
"command": "npx",
"args": [
"-y",
"@abhishekmcp/sql"
],
"env": {
"DB_CONN_default": "<db-conn-default>"
}
}
}
}Settings → Developer → Edit Config (claude_desktop_config.json), then restart.
Install in VS Code
{
"servers": {
"sql": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@abhishekmcp/sql"
],
"env": {
"DB_CONN_default": "<db-conn-default>"
}
}
}
}Add to .vscode/mcp.json in your workspace.
Install in Windsurf
{
"mcpServers": {
"sql": {
"command": "npx",
"args": [
"-y",
"@abhishekmcp/sql"
],
"env": {
"DB_CONN_default": "<db-conn-default>"
}
}
}
}Add to ~/.codeium/windsurf/mcp_config.json.
Configuration
| Variable | Required | Secret | Description |
|---|---|---|---|
| DB_CONN_default | — | yes | Connection URL for the 'default' connection (postgres://… or sqlite:/abs/path). Additional connections use DB_CONN_<name>. Carries credentials — treated as secret. |
| DB_WRITABLE | — | — | Set to 1 or true to enable the write tools (execute, execute_script). |
Freshness
Slowing — last maintenance signal 3mo ago. The newest of the signals below sets the band.
Last commit (default branch)
2026-07-04 · 3mo ago · GitHub
Latest release
2026-07-04 · 3mo ago · GitHub · http-v0.1.0
Package published
no data · npm/PyPI
Registry entry updated
2026-07-04 · 3mo ago · official registry · v0.1.0
FAQ
›How do I install the SQL MCP server in Claude Code?
Run: claude mcp add sql -e DB_CONN_default='<db-conn-default>' -- npx -y @abhishekmcp/sql. For Cursor, VS Code, Claude Desktop and Windsurf, use the install tabs above.
›Does SQL require an API key?
Yes. It expects DB_CONN_default, of which 1 is a secret.
›Can I use SQL as a remote (hosted) MCP server?
No hosted endpoint is published; it runs locally over stdio.
›Is SQL in the official MCP registry?
Yes, as io.github.Abhishekkumar2021/sql.
Alternatives to SQL
Other database MCP servers.