Supabase Rls Check
Read-only checks for Supabase row-level security, SQL exports and leaked public keys
Supabase Rls Check is an open-source MCP server for databases. It runs locally on your machine and is started by your AI client.
- Pricing
- Open source
- Platforms
- CLI, Self-hosted
- Runs
- Locally
- Version
- 0.7.0
- Listing updated
Similar MCP servers
Install
Add with the CLI
Run in a terminal
claude mcp add supabase-rls-check -- uvx supabase-rls-checkAdd --scope user to use it in every project, or --scope project to share it in .mcp.json.
Or share it with your project
Add to .mcp.json
{
"mcpServers": {
"supabase-rls-check": {
"command": "uvx",
"args": [
"supabase-rls-check"
]
}
}
}Add to claude_desktop_config.json
{
"mcpServers": {
"supabase-rls-check": {
"command": "uvx",
"args": [
"supabase-rls-check"
]
}
}
}Settings → Developer → Edit Config, then quit and reopen Claude Desktop.
Add to ~/.cursor/mcp.json
{
"mcpServers": {
"supabase-rls-check": {
"command": "uvx",
"args": [
"supabase-rls-check"
]
}
}
}Use .cursor/mcp.json in a project to share it with the project.
Add to ~/.copilot/mcp-config.json
{
"mcpServers": {
"supabase-rls-check": {
"type": "stdio",
"command": "uvx",
"args": [
"supabase-rls-check"
]
}
}
}Or put the same entry in .mcp.json at your workspace root to share it.
Add with the CLI
Run in a terminal
codex mcp add supabase-rls-check -- uvx supabase-rls-checkOr add to config.toml
Add to ~/.codex/config.toml
[mcp_servers.supabase-rls-check]
command = "uvx"
args = ["supabase-rls-check"]Add to your client's MCP settings (most use this shape)
{
"mcpServers": {
"supabase-rls-check": {
"command": "uvx",
"args": [
"supabase-rls-check"
]
}
}
}Gemini CLI and Antigravity
Gemini CLI
Add to ~/.gemini/settings.json
{ "mcpServers": { "supabase-rls-check": { "command": "uvx", "args": [ "supabase-rls-check" ] } } }Or run: gemini mcp add -s user supabase-rls-check uvx -- supabase-rls-check
Antigravity
Add to ~/.gemini/config/mcp_config.json
{ "mcpServers": { "supabase-rls-check": { "command": "uvx", "args": [ "supabase-rls-check" ] } } }Use .agents/mcp_config.json to add it to one workspace only.
Devin Desktop (formerly Windsurf)
Add to ~/.config/devin/mcp_config.json
{ "mcpServers": { "supabase-rls-check": { "command": "uvx", "args": [ "supabase-rls-check" ] } } }On Windows the file is %APPDATA%\devin\mcp_config.json. Use .devin/mcp_config.json to share it with a project.
Cline
Add to cline_mcp_settings.json
{ "mcpServers": { "supabase-rls-check": { "command": "uvx", "args": [ "supabase-rls-check" ] } } }Open it from the MCP Servers icon → Configure → Configure MCP Servers.
Zed
Add to Zed settings.json
{ "context_servers": { "supabase-rls-check": { "command": "uvx", "args": [ "supabase-rls-check" ] } } }Open it with zed: open settings file. Merge context_servers into the settings you already have.
JetBrains AI Assistant and Junie
AI Assistant
Add to Settings → Tools → AI Assistant → Model Context Protocol (MCP) → Add
{ "mcpServers": { "supabase-rls-check": { "command": "uvx", "args": [ "supabase-rls-check" ] } } }Junie
Add to ~/.junie/mcp/mcp.json
{ "mcpServers": { "supabase-rls-check": { "command": "uvx", "args": [ "supabase-rls-check" ] } } }Use .junie/mcp/mcp.json to share it with a project.
Kiro
Add to ~/.kiro/settings/mcp.json
{ "mcpServers": { "supabase-rls-check": { "command": "uvx", "args": [ "supabase-rls-check" ] } } }Use .kiro/settings/mcp.json to add it to one workspace only.
Using several servers? Build one config file with the MCP config generator.
About Supabase Rls Check
The tool exists because a Supabase app ships an anon or publishable key in browser code, so everything depends on row level security, grants and function permissions. The README lists the usual slips: a public table without RLS, a leftover USING (true) policy, and SECURITY DEFINER functions that PostgreSQL leaves executable by PUBLIC.
The workflow starts with a bundled SQL query you paste into the Supabase SQL Editor. It reads catalog metadata only, never rows, and you export the result. The CLI then normalizes that export, can probe what an anonymous caller can read, and writes an offline HTML report, a Markdown summary and a commented fix.sql wrapped in BEGIN and ROLLBACK that it never runs. A scan-env command looks through local files for service_role keys in client-exposed variables, and a GitHub Action can run the same check in CI.
The MCP mode is deliberately narrower than the CLI. It exposes four local read-only tools and leaves out network probing, so an AI client never handles API keys or makes HTTP requests through it.
Tools this server provides (4)
Taken from the project documentation; the running server may differ.
From the tool list in its README, going by the names, 2 of 4 tools read data; 2 names don't say.
From the server's own tool labels and tool names; not verified by us.
- analyze_sql_exportName suggests: reads
- Analyze an exported catalog-metadata result file.
- explain_ruleName suggests: reads
- Explain a rule's rationale, caveats and remediation.
- scan_public_env
- Scan a local project directory for secrets in public env variables.
- diff_results
- Compare two result files to show new and resolved findings.
What it does
- Catalog-only SQL export
- A bundled SELECT collects policy and grant metadata without touching application rows.
- Anonymous exposure probe
- Checks what an unauthenticated caller can read using only a public anon or publishable key.
- Public env secret scan
- Finds service_role keys, secret keys and database URLs in client-bundled variables and source files, with values masked.
- Run-to-run diff
- Shows new and resolved findings between two result files and can fail on new ones.
- Report and fix template
- Writes HTML and Markdown reports plus a rollback-wrapped fix.sql for review.
- CI action
- Runs the check in a read-only psql session and fails a job at a chosen severity.
Good for
- Audit RLS before launching a Supabase app
- Catch a service_role key left in NEXT_PUBLIC or VITE variables
- Review AI-generated migrations for missing policies
- Gate pull requests on new high-severity findings
- Understand why a rule such as rls_disabled matters
Pricing
Open source
Free PyPI package
Supabase Rls Check FAQ
Does Supabase Rls Check need my database password or service_role key?
No. The README says neither is required, and probe rejects service_role and authenticated tokens before sending a request.
Does the MCP server make network calls?
No. Network probing is excluded from MCP so AI clients never handle API keys or send HTTP requests through it.
What Python version is needed?
Python 3.11 or newer, with Supabase on PostgreSQL 15 or newer.
Can the report be in another language?
Add --lang vi for Vietnamese report text.
Will Supabase Rls Check apply the fixes?
No. fix.sql is a commented review template that the tool never executes.
Is Supabase Rls Check free?
Yes. Supabase Rls Check is open source, so you can use and self-host it for free.
How do I add Supabase Rls Check to Claude Code?
Run this command in your terminal: claude mcp add supabase-rls-check -- uvx supabase-rls-check
What are the best alternatives to Supabase Rls Check?
The closest alternatives to Supabase Rls Check are REA, AiSOC, x64dbg-mcp-server, redamon and Treasure Map.
Where this comes from
- Description: written from the project's README.
- Install steps: from the official MCP Registry entry.



