sqlsure
MCP server by sqlsure Community
sqlsure is a semantic SQL inspector for AI-written queries. It flags double-counting, wrong joins and PII exposure before a query runs. It can run as a CI gate, an MCP server or a Python library.
Install sqlsure
Built from the published package, never by AI.
claude mcp add sqlsure -- uvx sqlsureRun in your terminal. Add --scope user to use it in every project.
{
"mcpServers": {
"sqlsure": {
"args": [
"sqlsure"
],
"command": "uvx"
}
}
}Settings, Developer, Edit config. Paste into claude_desktop_config.json and restart.
{
"mcpServers": {
"sqlsure": {
"args": [
"sqlsure"
],
"command": "uvx"
}
}
}Add to ~/.cursor/mcp.json (all projects) or .cursor/mcp.json (this project).
{
"servers": {
"sqlsure": {
"args": [
"sqlsure"
],
"command": "uvx"
}
}
}Add to .vscode/mcp.json. VS Code uses "servers", not "mcpServers".
codex mcp add sqlsure -- uvx sqlsure{
"mcpServers": {
"sqlsure": {
"args": [
"sqlsure"
],
"command": "uvx"
}
}
}Add to ~/.gemini/config/mcp_config.json (all projects) or .agents/mcp_config.json (this project).
gemini mcp add sqlsure uvx sqlsureGemini CLI was replaced by Antigravity CLI in June 2026 and remains only for enterprise licences and paid API keys.
MCP servers run with your permissions and can read what you give them access to. Some need an API key: check the README and add it under env in the sqlsure block.
About
sqlsure is a semantic SQL inspector. It checks a query against facts a team has already declared, such as dbt unique and relationships tests, and flags problems like double-counting, wrong joins and PII exposure before the query runs. Its rules are dictionary lookups rather than LLM calls, so the same input gives the same verdict. When it cannot verify something, it says so.
Each rejection includes a fix that an AI agent can apply to repair its query. sqlsure can run as a CI gate, as an MCP server for AI agents, or as a Python library with a check() function. It works offline and parses query text only, without connecting to a database. It is aimed at teams that let AI write SQL and want to verify results before execution.
Written from the project's README and checked against it.
What you need
- Python
- pip
Try asking
- Check this SQL for double-counting before I run it.
- Flag any PII columns exposed in this query's output.
- Verify that the joins in this query match our declared relationships.
Good to know
- Version 0.1 with nine rules.
- Parses query text only and never connects to a database.
- Judges joins only against declared facts such as dbt tests or a model file.
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: README.md. This looks for known risky patterns and is not a full audit. How grades work
What you can do with it
- Catch double-counted joins in AI-written SQL
- Gate SQL changes in CI before merge
- Flag PII columns in query output
Alternatives to sqlsure
All alternatives →Connects Supabase projects to AI assistants such as Cursor, Claude and Windsurf over the Model Context Protocol. It lets assistants manage tables, fetch config and query data in a Supabase project.
ArcadeDB MCP Server is the built-in Model Context Protocol server of the ArcadeDB multi-model database. It lets AI assistants and LLMs work with ArcadeDB's graph, document, time-series, vector and other data models. It suits people who already run ArcadeDB and want assistant access to it.
Connects MCP clients such as Claude Desktop, Cursor and VS Code to PostgreSQL, MySQL, MariaDB, SQL Server, Oracle, ClickHouse and SQLite. It exposes two tools by default, with read-only mode and query timeouts available as guardrails.
MCP Toolbox for Databases is an open source MCP server that connects AI agents, IDEs and applications to enterprise databases. It provides prebuilt tools for exploring schemas and running queries, plus a framework for custom tools. It is aimed at developers building agents that need database access.
Connects AI agents, IDEs and applications to enterprise databases through the Model Context Protocol. Offers prebuilt database tools for MCP clients and a framework for building custom tools for production agents.
MongoDB MCP Server lets AI assistants interact with MongoDB databases and MongoDB Atlas. It is an official server from mongodb-js, run locally with npx or Docker. It works with self-managed deployments and Atlas clusters.
Compare with Supabase, ArcadeDB MCP Server or DBHub
sqlsure: common questions
What kinds of SQL errors does sqlsure catch?
The source lists rules for fan-out double-counting, chasm joins, summing non-additive measures, semi-additive balances, joins on undeclared keys, cross joins, weighted averages, undeclared joins and PHI or PII columns in output.
Does sqlsure send my SQL anywhere?
The source says it runs offline with zero network calls, so SQL never leaves the user's machine. It also collects no telemetry.
Where does sqlsure get its rules?
The source says rules come from dbt manifest.json or schema.yml files, plain PK and FK declarations, the live database catalog for SQLite or information_schema, hand-written JSON, and OSI or WrenAI MDL loaders.
How do I install sqlsure?
In Claude Code run claude mcp add sqlsure -- uvx sqlsure. For Claude Desktop, Cursor and VS Code, paste the config shown above and restart. See the install guides.
Is sqlsure the official server?
sqlsure is a community project by sqlsure, not verified by a company domain.
Is sqlsure free?
The code is published under the Apache-2.0 licence. The service it connects to may have its own pricing.
Is sqlsure safe to use?
It scores 78 of 100. Grades: maintenance A, licence A, quality B. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to sqlsure?
Similar MCP servers: Supabase, ArcadeDB MCP Server, DBHub, MCP Toolbox for Databases.
Does sqlsure work with ChatGPT?
Not directly. It runs locally, and ChatGPT only connects to remote servers with a URL. Use it in Claude Code, Claude Desktop, Cursor, VS Code or Codex.
