Skip to content
MCP server

Orion Gate

Open-source SQL firewall that sits between AI agents and production databases

Orion Gate is an open-source MCP server for databases. It runs as a hosted remote server, so there is nothing to install locally.

Pricing
Open source
Platforms
API, CLI, Self-hosted
Runs
Remotely
What it can do
Read-only
Version
0.4.1

Similar MCP servers

Install

Add with the CLI

Run in a terminal

claude mcp add --transport http orion-gate https://api.oriongate.dev/mcp

Add --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": {
    "orion-gate": {
      "type": "http",
      "url": "https://api.oriongate.dev/mcp"
    }
  }
}

Claude Code setup guide

In Customize → Connectors → Add → Add custom connector

https://api.oriongate.dev/mcp

Paste this URL, choose how to sign in, then click Add and Connect. On Team and Enterprise an Owner adds it in Organization settings → Connectors.

Claude Desktop setup guide

Install in CursorOpens Cursor, which asks you to confirm. Or add it by hand:

Add to ~/.cursor/mcp.json

{
  "mcpServers": {
    "orion-gate": {
      "url": "https://api.oriongate.dev/mcp"
    }
  }
}

Use .cursor/mcp.json in a project to share it with the project.

Cursor setup guide

Install in VS CodeOpens VS Code, which asks you to confirm. Or add it by hand:

Add to ~/.copilot/mcp-config.json

{
  "mcpServers": {
    "orion-gate": {
      "type": "http",
      "url": "https://api.oriongate.dev/mcp"
    }
  }
}

Or put the same entry in .mcp.json at your workspace root to share it.

VS Code setup guide

In chatgpt.com → Plugins → + → Add custom MCP server

https://api.oriongate.dev/mcp

Paste this URL, set up sign-in, accept the warning and install the plugin. Then type @ in a chat to use it.

ChatGPT setup guide

Add with the CLI

Run in a terminal

codex mcp add orion-gate --url https://api.oriongate.dev/mcp

Or add to config.toml

Add to ~/.codex/config.toml

[mcp_servers.orion-gate]
url = "https://api.oriongate.dev/mcp"

Codex setup guide

Add to Grok Bot desktop app → Connect apps → Add a custom connector

https://api.oriongate.dev/mcp

Enter a Name (for example "Orion Gate"), choose Type: Remote HTTPS, paste this as the Server URL and choose Add plugin.

Full Grok Bot setup guide

Add to your client's MCP settings (most use this shape)

{
  "mcpServers": {
    "orion-gate": {
      "type": "http",
      "url": "https://api.oriongate.dev/mcp"
    }
  }
}
  • Gemini CLI and Antigravity

    Gemini CLI

    Add to ~/.gemini/settings.json

    {
      "mcpServers": {
        "orion-gate": {
          "httpUrl": "https://api.oriongate.dev/mcp"
        }
      }
    }

    Or run: gemini mcp add -s user --transport http orion-gate https://api.oriongate.dev/mcp

    Antigravity

    Add to ~/.gemini/config/mcp_config.json

    {
      "mcpServers": {
        "orion-gate": {
          "serverUrl": "https://api.oriongate.dev/mcp"
        }
      }
    }

    Use .agents/mcp_config.json to add it to one workspace only.

    Gemini CLI and Antigravity setup guide

  • Devin Desktop (formerly Windsurf)

    Add to ~/.config/devin/mcp_config.json

    {
      "mcpServers": {
        "orion-gate": {
          "url": "https://api.oriongate.dev/mcp",
          "transport": "http"
        }
      }
    }

    On Windows the file is %APPDATA%\devin\mcp_config.json. Use .devin/mcp_config.json to share it with a project.

    Devin Desktop setup guide

  • Cline

    Add to cline_mcp_settings.json

    {
      "mcpServers": {
        "orion-gate": {
          "type": "streamableHttp",
          "url": "https://api.oriongate.dev/mcp"
        }
      }
    }

    Open it from the MCP Servers icon → Configure → Configure MCP Servers.

    Cline setup guide

  • Zed

    Add to Zed settings.json

    {
      "context_servers": {
        "orion-gate": {
          "url": "https://api.oriongate.dev/mcp"
        }
      }
    }

    Open it with zed: open settings file. Merge context_servers into the settings you already have.

    Zed setup guide

  • JetBrains AI Assistant and Junie

    AI Assistant

    Add to Settings → Tools → AI Assistant → Model Context Protocol (MCP) → Add

    {
      "mcpServers": {
        "orion-gate": {
          "url": "https://api.oriongate.dev/mcp"
        }
      }
    }

    Junie

    Add to ~/.junie/mcp/mcp.json

    {
      "mcpServers": {
        "orion-gate": {
          "url": "https://api.oriongate.dev/mcp"
        }
      }
    }

    Use .junie/mcp/mcp.json to share it with a project.

    JetBrains AI Assistant and Junie setup guide

  • Kiro

    Add to ~/.kiro/settings/mcp.json

    {
      "mcpServers": {
        "orion-gate": {
          "url": "https://api.oriongate.dev/mcp"
        }
      }
    }

    Use .kiro/settings/mcp.json to add it to one workspace only.

    Kiro setup guide

Using several servers? Build one config file with the MCP config generator.

About Orion Gate

Orion Gate runs as a proxy in front of PostgreSQL, MySQL and BigQuery, so an AI agent never talks to the database directly. Every query is parsed into an AST, checked against schema allowlists, and rewritten to add per-tenant WHERE and JOIN filters before anything executes against the database.

Beyond query rewriting, it trims the schema the agent sees, blocks risky constructs such as SELECT *, cross joins, row-locking clauses and dangerous functions, and applies k-anonymity limits to small result groups. Returned rows are passed through masking rules and secret redaction for emails, phone numbers, card numbers, SSNs and API keys.

It is aimed at teams that expose production data to LLM agents through MCP or REST and want deterministic guardrails rather than trusting prompts. It is meant to sit alongside read-only database roles and row-level security, not replace them.

Tools this server provides (3)

Taken from the project documentation; the running server may differ.

From the tool list in its README, going by the names, all 3 tools only read data.

From the server's own tool labels and tool names; not verified by us.

list_allowed_tablesName suggests: reads
Lists only tables visible to the caller's projected scope.
describe_table_schemaName suggests: reads
Returns projected column names and types with sensitive fields stripped.
query_governed_sqlName suggests: reads
Validates and rewrites SQL with tenant predicates, runs it read-only, and masks PII and secrets in results.

What it does

Tenant filter injection
Adds tenant predicates to every base-table scope of a query, including subqueries, CTEs, joins and unions.
Schema projection
Hides denied tables, sensitive columns and raw JSON fields from the agent before it plans a query.
Read-only SQL enforcement
Allows only SELECT and WITH statements and rejects DDL, DML, multi-statements and locking clauses.
Result masking
Masks or redacts emails, phones, Luhn-valid cards, SSNs, tokens and database URIs in returned rows.
Small-group suppression
Suppresses aggregate results below a configured group size and blocks common differencing query patterns.
Scoped agent tokens
Mints short-lived HS256 JWTs bound to a tenant so agents cannot override the tenant through headers.

Good for

  • Letting a support chatbot query customer order data without seeing other tenants' rows
  • Giving an internal analytics agent read access to a production database with PII masked
  • Exposing governed database tools to Claude Desktop or Cursor over MCP
  • Adding a policy layer in front of LangGraph or CrewAI agents that run SQL
  • Auditing and blocking prompt-injected queries before they reach the database

Pricing

Open source

Free and open-source under Apache 2.0; self-hosted.

Orion Gate FAQ

Is Orion Gate free to use?

It is open-source under the Apache License 2.0 and runs standalone with no external control plane required.

Which databases are supported?

PostgreSQL, MySQL and BigQuery, with optional extras installed per engine.

How does an MCP client connect?

Point the client at the streamable HTTP endpoint at /mcp on the running server, passing a bearer token in the Authorization header.

Does Orion Gate add latency?

The README reports a median of about 4.8 ms for AST policy validation on its benchmark machine, excluding database execution time.

How do I add Orion Gate to Claude Code?

Run this command in your terminal: claude mcp add --transport http orion-gate https://api.oriongate.dev/mcp

What are the best alternatives to Orion Gate?

The closest alternatives to Orion Gate are SQL MCP Server, AgentSQL, Warehouse MCP, DBShield Database Guardrail & Sandboxing MCP Server and Safedb MCP.

Where this comes from

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

How AIPoweredBot checks servers