Secure Schema MCP logo

Secure Schema MCP

Read-only MCP access to allowlisted database schema metadata, with no row queries or write operations.

Install Secure Schema MCP

Pick your client, then add it in one click or paste the config.

STDIOPython
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "secure-schema-mcp": {
      "command": "uvx",
      "args": [
        "mcp-secure-schema"
      ],
      "env": {
        "DATABASE_URL": "YOUR_VALUE_HERE"
      }
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

Values are written into the snippet above so you can paste it as is. They never leave your browser.

Automated check passed— started and listed 3 tools correctly ().

Overview

Secure Schema MCP MCP server exposes allowlisted schema metadata from SQLite, PostgreSQL, or MySQL databases through three MCP tools. It uses SQLAlchemy connection URLs and returns tables, views, columns, types, keys, constraints, and foreign-key relationships without row values or query results. Compact output helps limit token usage, while markdown output is available for human-readable inspection. Reach for it when coding agents need database structure but should not access application data.

Use cases

  • Inspect database structure while keeping row data inaccessible
  • Give coding agents an allowlisted table and view inventory
  • Review primary-key and foreign-key relationships in compact output
  • Expose schema metadata from SQLite, PostgreSQL, or MySQL

Key features

  • Read-only SQLAlchemy schema inspection
  • Allowlisted tables and views
  • Primary, unique, and foreign-key metadata
  • Compact and markdown output formats
  • Sanitized client-facing errors
  • Production namespace locking

Tools3

What Secure Schema MCP lets your agent do. Expand a tool for its parameters.

Verified live~464 tokens of context

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked

Recent health check succeeded.

19/23 checks healthy over the last 111d

What it can do

From the 3 tools this server returned when we ran it.

Read-only tools · 3
Network at startup2 connections
Files written at startup1

Observed 2026-10-20 in an isolated sandbox. A description of reach, not a security audit.

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 9d ago via OSV.dev · mcp-secure-schema (PyPI)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

Last commit4mo agoMost recent push to the default branch.
Availability100%Our rolling endpoint + install checks that succeeded.
Install checkPassedOur sandbox started it and listed its tools.
Tools exposed3Callable tools this server registers over MCP.
Directory activity1 viewsConfig copies, upvotes, and views on AllMCPs.

How Secure Schema MCP works

What Secure Schema MCP MCP server does

Secure Schema MCP provides AI coding tools with database structure while keeping row data outside the MCP interface. It can expose table and view names, column names and SQL types, nullability, primary keys, unique constraints, and foreign-key relationships. The server does not provide SQL query execution, row samples, row counts, mutation tools, or database credentials.

The server supports reachable SQLite, PostgreSQL, and MySQL databases. SQLite uses Python's built-in driver; PostgreSQL and MySQL drivers are included. Other SQLAlchemy dialects are not tested or bundled in version 1.

How it works

The server runs as a Python MCP process over standard input and output. An MCP-compatible client starts it when needed, typically through uvx or an installed mcp-secure-schema command. It performs SQLAlchemy inspection operations against the configured database and returns only metadata permitted by the configured namespace and table allowlist.

Three tools are available:

  • schema_overview returns a compact map of permitted tables, views, primary keys, and foreign-key links.
  • list_tables returns the permitted table and view inventory.
  • inspect_table returns detailed metadata for one permitted entity.

Tools default to compact formatting to reduce model context usage. Callers can request markdown when a more readable representation is preferable. When an allowlist is active, missing and disallowed names use the same client-facing message, reducing the chance of revealing whether an object exists. Operational details are written to standard error and client-facing errors are sanitized.

Setup and configuration

The Secure Schema MCP MCP server requires DATABASE_URL, which accepts a SQLAlchemy URL. Examples include absolute-path SQLite URLs, PostgreSQL URLs using psycopg2, and MySQL URLs using pymysql. Reserved characters in usernames and passwords must be percent-encoded. Remote connections also require working DNS, network and firewall access, and valid TLS settings where applicable.

The recommended installation uses uvx, which downloads and runs the published package in an isolated environment. A persistent alternative is pipx install mcp-secure-schema; the installed command can then be used directly in the MCP client configuration. Python 3.12 or newer is needed when installing without uvx.

DATABASE_SCHEMA selects the default schema or catalog namespace. In production, it is treated as a security boundary and cannot be overridden by tool arguments. Outside production, an explicit tool schema can override it. SECURE_SCHEMA_ENV=production or prod enables strict startup validation, including the requirement for a non-empty ALLOWED_TABLES value. For multiple production schemas, configure one server entry per schema and allowlist.

Use a dedicated least-privilege database account. Do not commit credentials in client configuration; a wrapper can obtain DATABASE_URL from an operating-system keychain or secret manager. The server's configuration and launching IDE should be treated as trusted.

Limitations and notes

The Secure Schema MCP MCP server reveals metadata, which can still be sensitive: names such as ssn may disclose information even though values remain inaccessible. The allowlist is therefore important for production deployments. Its entries are comma-separated, case-sensitive, unqualified table or view names rather than schema.table values.

Database metadata visibility depends on the database provider's policies and permissions. PostgreSQL deployments may need additional catalog or object privileges for inspection; avoid granting row SELECT unless required by the environment. A process started directly may appear to hang because it is waiting for an MCP client on standard input. If startup fails, check that DATABASE_URL is present and that production mode has a non-empty allowlist.

Written by AllMCPs with AI assistance from the project’s README and listing data. How we build listings

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Secure Schema MCP

Secure Schema MCP is an MCP server that connects AI coding tools to reachable SQLite, PostgreSQL, or MySQL databases through SQLAlchemy URLs. Its main tools are schema_overview, list_tables, and inspect_table, which expose permitted schema metadata—tables, views, columns, keys, and relationships—without row values or query results.

Install it with `uvx` in the MCP client configuration or run `pipx install mcp-secure-schema` for a persistent installation. Configure `DATABASE_URL` and start the command through an MCP-compatible client such as Cursor or Codex.

Yes, Secure Schema MCP works with Cursor through its MCP configuration. Add a server entry that runs `uvx` with the `mcp-secure-schema` argument, provide `DATABASE_URL`, and reload Cursor after changing the configuration.

Set `ALLOWED_TABLES` to a comma-separated, case-sensitive list of permitted table and view names. Production mode refuses to start without a non-empty allowlist, and disallowed names return the same message as missing names when the allowlist is active.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewSecure Schema MCP AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/secure-schema-mcp?style=directory)](https://allmcps.com/mcp/secure-schema-mcp)
HTML Embed
<a href="https://allmcps.com/mcp/secure-schema-mcp"><img src="https://allmcps.com/api/badge/secure-schema-mcp?style=directory" alt="Secure Schema MCP on AllMCPs" /></a>