sqlite-explorer-mcp
Provides read-only access to SQLite databases, allowing exploration of tables and columns via resources, and running SELECT queries via a tool. Supports both local (stdio) and remote (HTTP) transports with safety features.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@sqlite-explorer-mcpshow me the customers table schema"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
sqlite-explorer-mcp
A production-grade Model Context Protocol server that exposes a read-only SQLite database to any MCP client (Claude Code, Claude Desktop, …). It ships both transports, real input/output bounds, structured logging, auth, tests, CI, and a container.
Built on the official @modelcontextprotocol/sdk (v1.29.x).
Design
Capability | MCP primitive | Why |
Discover tables / columns | Resource ( | Read-only context the model reads; cacheable, side-effect-free |
Run a query | Tool ( | An action with cost/risk: validated input, can fail, auditable |
The server is defined once (src/server.ts) and exposed over two transports from shared code:
src/stdio.ts— for local clients (the client launches it as a subprocess).src/http.ts— Streamable HTTP for remote clients on other machines.
Related MCP server: sqlite-mcp-server
Safety
The read-only boundary is the engine, not a string check. The DB is opened
{ readonly: true }withPRAGMA query_only = ON; SQLite rejects any write regardless of the SQL sent. The single-statement / SELECT-only gate insrc/db.tsonly produces clearer errors.Output is bounded —
MAX_ROWScap +busy_timeoutso a runaway scan can't exhaust memory.Secrets via Zod-validated env (
src/env.ts); nothing hardcoded. HTTP requires a 32+ charMCP_BEARER_TOKEN, checked with a constant-time compare and fail-closed.The stdout rule — on stdio, stdout is the JSON-RPC channel. All logging goes to stderr (
src/logger.ts); an ESLintno-consolerule enforces it.
Quick start
npm install
npm run seed # creates data.db (sample customers + orders)
npm test # unit + in-memory integration tests
npm run buildRun locally (stdio) + connect to Claude Code
npx @modelcontextprotocol/inspector node build/stdio.js # debug standalone first
claude mcp add --transport stdio sqlite -- node "$(pwd)/build/stdio.js"Run remotely (Streamable HTTP)
export MCP_BEARER_TOKEN=$(openssl rand -hex 32)
npm run start:http
# from any machine (behind TLS in production):
claude mcp add --transport http sqlite https://your-host/mcp \
--header "Authorization: Bearer $MCP_BEARER_TOKEN"Confirm with claude mcp list and /mcp inside a session.
Docker
docker build -t sqlite-explorer-mcp .
docker run --rm -p 8080:8080 \
-e MCP_BEARER_TOKEN=$(openssl rand -hex 32) \
-e BIND_HOST=0.0.0.0 \
-v "$(pwd)/data.db:/app/data.db:ro" \
sqlite-explorer-mcpTerminate TLS at a reverse proxy in front of the container; never expose the plain HTTP port publicly. For per-user identity/revocation, Streamable HTTP also supports OAuth 2.0 — ship the bearer token first and add OAuth only when compliance requires named-user attribution.
Configuration
All via environment (see .env.example): SQLITE_PATH, PORT, BIND_HOST, MCP_BEARER_TOKEN,
MAX_ROWS, QUERY_TIMEOUT_MS, LOG_LEVEL.
License
MIT
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Tools
Related MCP Servers
- Alicense-qualityCmaintenanceExposes sqlite3 database functionality as MCP tools, enabling SQL query execution, schema management, and CRUD operations.Last updated1MIT
- Alicense-qualityCmaintenanceA read-only MCP server that enables LLMs to safely explore and query any SQLite database via natural language. It exposes tools for listing tables, describing schemas, and executing SELECT/WITH queries with built-in safety guards like write prevention and row limits.Last updatedMIT
- Flicense-qualityCmaintenanceCustom MCP server connected to a read-only SQLite database, exposing a schema resource and a query tool for safe data retrieval.Last updated
- Alicense-qualityCmaintenanceRead-only MCP server for SQLite databases, enabling AI assistants to safely query and inspect database schemas without write access.Last updatedMIT
Related MCP Connectors
Read-only MCP server for ClassQuill, a tutoring-business-management platform.
UN FAOSTAT global food & agriculture statistics over a local SQLite mirror, via MCP.
Search your AI chat history (ChatGPT, Claude, Codex) from any MCP client. Remote, private, read-only
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/FrankieSoltero/sqlite-explorer-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server