SQLite MCP Server

Ask Claude or Cursor questions about any SQLite file, with the data protected: read-only by default, capped results, no runaway queries.

SQLite MCP Server product illustration

What it does

Point Claude Code, Claude Desktop, Cursor or any MCP client at a SQLite file and ask questions in plain English: "revenue by month", "which customers ordered twice and then stopped", "why is this query slow". The server is read-only unless you turn writes on, caps results, stops runaway queries, and never lets the model attach other files or load extensions.

  • 7 tools: list_databases, list_tables (with row counts), describe_table (columns, keys, foreign keys, indexes, CREATE SQL, sample rows), read_query, explain_query (flags full scans and temp sorts), search_schema, export_csv. write_query appears only with --allow-writes.
  • Safety in layers: the file is opened mode=ro; a SQLite authorizer allows only SELECT, reads and read-only PRAGMAs; ATTACH/DETACH and load_extension are always blocked; one statement per call; ? parameters; row cap (default 200); time limit (default 10 s); writes run in a transaction and roll back on error.
  • Several databases at once: --db app.db --db analytics=/data/events.sqlite.
  • Python 3.9+ standard library only. No install, no Node, no network. Works with Django, Rails, Prisma, Drizzle, Turso exports, browser history, Anki, Apple Notes copies... any SQLite file.
  • MCP 2026-07-28 and the 2025-11-25 handshake on the same server, so new and older clients both connect.
  • Claude Code plugin with the sqlite-analyst skill (schema first, parameterized SQL, explain slow queries, confirm writes).

What you get

The screenshot is real output from the kit’s own commands. Tested from a fresh download of this exact zip: ./run_tests.sh ran 13 tests OK on Python 3.13 and 3.10.

Real terminal output from SQLite MCP Server: demo and passing tests

Install

Claude Code (plugin): copy this folder somewhere permanent, then

export SQLITE_MCP_DB=/absolute/path/to/app.db
claude --plugin-dir /path/to/sqlite-mcp-server

Claude Code (just the server): claude mcp add sqlite -- python3 /path/to/sqlite-mcp-server/server.py --db /path/to/app.db

Claude Desktop / Cursor: see examples/configs/ (absolute paths). Restart the app.

Options: --allow-writes, --max-rows 500, --timeout 30. Environment: SQLITE_MCP_DB (several paths separated by :; ; on Windows), SQLITE_MCP_ALLOW_WRITES=1.

Try it

./demo.sh builds a fictional coffee shop database (60 customers, 186 orders) and runs a real MCP session: tables, schema, revenue by month, a query plan, and a blocked DELETE. ./run_tests.sh runs 13 tests (including MCP protocol tests).

Honest limits

  • SQLite only (not Postgres or MySQL). For a big production database, point it at a copy or a read replica file.
  • The model writes the SQL. Read-only mode protects the data, not the correctness of an answer; check the query it shows you.
  • Values over 2,000 characters and blobs are shortened in results.
  • Not affiliated with SQLite or Anthropic.

Related: CSV MCP Server: https://youraitools.co/marketplace/csv-mcp-server. MCP Config Validator: https://youraitools.co/marketplace/mcp-config-validator

Format and license

Zip, 25 KB, v1.0, 21 files. You may use and modify this kit for your own work and for clients you serve, including paid client work. Not affiliated with or endorsed by SQLite, Anthropic or Cursor (Anysphere).

FAQ

Can the model delete my data?
Not by default: the file is opened read-only and an authorizer blocks every write. Writes need --allow-writes, and the skill asks you before running one.
Does it work with Postgres?
No, SQLite files only. Export a copy to SQLite or use a Postgres-specific server.
Do I need Node or pip install?
No, Python 3.9+ with the standard library.
How do I get the files?
Pay by card right here on youraitools.co: your download links appear on this page the moment the payment goes through (claim window: 72 hours, up to 5 downloads per 7 days). Need the files re-sent later? Email hello@youraitools.co.
Refunds?
Email hello@youraitools.co within 14 days if it doesn’t work and we can’t fix it.
Can I pay with crypto?
Yes. Pay the same price in USDC or USDT on Base, Ethereum, Arbitrum, Optimism, Polygon or Solana from the "Pay with crypto" button, with no account or KYC. We check the payment on-chain and show your download links as soon as it confirms.

Get SQLite MCP Server

SQLite MCP server for Claude Code, Claude Desktop and Cursor: schema, parameterized read-only SQL, query plans, CSV export, row caps. Python, no deps. $29.

Save with a bundle

Pairs well with

Download$19

Claude Code Slash Commands Pack

24 ready Claude Code slash commands (/commit, /ship, /fix-tests, /handoff...), a linter for custom commands and a cheat sheet of every built-in. $19.

View Claude Code Slash Commands Pack
DownloadFree

Claude Code Statusline Kit (Free)

Free Claude Code statusline: context bar, session cost, 5-hour and weekly limits with reset times, cache, git and PR. One-command install, Python, no deps.

View Claude Code Statusline Kit (Free)
DownloadFree

Claude Code Usage Report (Free)

Free CLI: see Claude Code tokens and API-equivalent cost by day, project, model, session and 5-hour window from local logs. No install, offline.

View Claude Code Usage Report (Free)

Related

1 email a week: new x402 + MCP tools and free kits.

Short weekly digest of new x402 + MCP tools and free kits, including the MCP OAuth Checker. No spam, unsubscribe any time.