
esmole
Read-only Elasticsearch 7 and 8 access where the agent manages connections at runtime
- Pricing
- Open source
- Platforms
- CLI, self-hosted
- Runs
- Locally
- Version
- 0.2.0
- Listing updated
- 1 day ago
About esmole
esmole is an open-source MCP server for databases. It runs locally on your machine and is started by your AI client.
esmole-mcp lets an agent add, edit and remove Elasticsearch clusters through tools during a session instead of editing client config. A request like connect to the logs cluster through a bastion, readonly, calls add_connection, and the entry is saved to a per-project .esmole.json or a global store that is re-read on every call, so no restart is needed.
It supports Elasticsearch 7.x and 8.x with API key or basic auth, any number of named clusters, and SSH tunnels using password, key or agent auth with host keys checked against known_hosts or a pinned fingerprint. Readonly connections allow only a list of read endpoints, with absolute timeouts, a 10 MB response cap and a 40 KB result cap so a large aggregation does not flood context.
Credentials are never echoed back and invalid entries are reported instead of silently skipped. It needs Node 22 or newer.
Install
Run in a terminal
claude mcp add esmole-mcp -- npx -y esmole-mcpAdd to claude_desktop_config.json
{
"mcpServers": {
"esmole-mcp": {
"command": "npx",
"args": [
"-y",
"esmole-mcp"
]
}
}
}Add to ~/.cursor/mcp.json
{
"mcpServers": {
"esmole-mcp": {
"command": "npx",
"args": [
"-y",
"esmole-mcp"
]
}
}
}Add to .vscode/mcp.json
{
"servers": {
"esmole-mcp": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"esmole-mcp"
]
}
}
}Add to ~/.codeium/windsurf/mcp_config.json
{
"mcpServers": {
"esmole-mcp": {
"command": "npx",
"args": [
"-y",
"esmole-mcp"
]
}
}
}Add to your client's MCP settings (most use this shape)
{
"mcpServers": {
"esmole-mcp": {
"command": "npx",
"args": [
"-y",
"esmole-mcp"
]
}
}
}What it does
- Runtime connections
- Add and remove clusters from the agent.
- SSH tunnels
- Password, key or agent auth with host key checks.
- Readonly mode
- Allowlist of read endpoints only.
- Response caps
- 10 MB responses, 40 KB results.
- Per-project config
- Project file or global store, hot-reloaded.
- Hidden credentials
- Secrets are not echoed.
Good for
- Query logs on a cluster behind a bastion host
- Explore index sizes without leaving the chat
- Switch between several clusters per project
- Avoid accidental writes with readonly mode
Pricing
Open source
Free npm package.
esmole FAQ
What versions are supported?
Elasticsearch 7.x and 8.x.
Do I edit client config?
No, connections are managed by tools and reload on each call.
What Node version?
22 or newer.
Is there a SQL variant?
The README points to dbmole-mcp for PostgreSQL and MySQL.
Is esmole free?
Yes. esmole is open source, so you can use and self-host it for free.
How do I add esmole to Claude Code?
Run this command in your terminal: claude mcp add esmole-mcp -- npx -y esmole-mcp
What are the best alternatives to esmole?
The closest alternatives to esmole are REA, Codebase Memory, GitHub, Serena MCP: the IDE for your agent and XERJ.
Alternatives to esmole

REA
MCP serverCLI and MCP server that lets coding agents reverse engineer apps and binaries
Runs locally- Open source
- 464K GitHub stars
- Developer tools

Codebase Memory
MCP serverLocal MCP server that builds a code knowledge graph for AI coding agents
Runs locally- Open source
- 48.7K GitHub stars
- Knowledge and memory

GitHub
MCP serverOfficial MCP server connecting AI assistants to GitHub repos, issues and workflows
Not checked yet- Remote
- Open source
- 34.5K GitHub stars
- Developer tools

Serena MCP: the IDE for your agent
MCP serverMCP toolkit giving coding agents symbol-level code retrieval and editing
Runs locally- Open source
- 31.5K GitHub stars
- Developer tools

XERJ
MCP serverLocal search engine for AI agents with cited answers over your code and docs
Runs locally- Open source
- 19.2K GitHub stars
- Knowledge and memory

Ouroboros
MCP serverSpec-first layer that pins requirements and verifies results of AI coding agent work
Runs locally- Open source
- 6.4K GitHub stars
- Developer tools