Skip to main content
Watch: I Built an AI App Without Leaving Databricks

Databases - official Elastic server

Elasticsearch MCP server

Standalone container MCP server that connects an agent to an Elasticsearch 8.x or 9.x cluster to list indices, read mappings, and run Query DSL and ES|QL queries. Elastic has deprecated it in favor of the Agent Builder MCP endpoint. It runs locally from docker.elastic.co/mcp/elasticsearch (docker) with API key auth.

Last verified 5 tools3 sources

Install

Generic

JSON
{
  "mcpServers": {
    "elasticsearch-mcp-server": {
      "command": "docker",
      "args": [
        "run", "-i", "--rm",
        "-e", "ES_URL",
        "-e", "ES_API_KEY",
        "docker.elastic.co/mcp/elasticsearch",
        "stdio"
      ],
      "env": {
        "ES_URL": "<elasticsearch-cluster-url>",
        "ES_API_KEY": "<elasticsearch-API-key>"
      }
    }
  }
}

Tools

list_indices
List all available Elasticsearch indices.
get_mappings
Get field mappings for a specific Elasticsearch index.
search
Perform an Elasticsearch search using query DSL.
esql
Execute an ES|QL query.
get_shards
Get shard information for all or specific indices.

As documented on October 17, 2026. A running server reports its current list through tools/list.

Notes and caveats

  • DEPRECATED: the README says it will only receive critical security updates and has been superseded by the Elastic Agent Builder MCP endpoint (Elastic 9.2.0+ and Serverless).
  • Version 0.4.0+ ships as a Docker image (also on AWS Marketplace).
  • The npm package @elastic/mcp-server-elasticsearch stops at 0.3.1 (July 2025) and is itself marked deprecated.
  • Auth is an API key or username and password (ES_USERNAME, ES_PASSWORD).
  • In HTTP mode the endpoint is http://<host>:8080/mcp, with a health check at /ping.
  • SSE is deprecated.
  • The status enum has no 'deprecated' value, so status is set to unknown.

FAQ

What does the Elasticsearch MCP server do?

Standalone container MCP server that connects an agent to an Elasticsearch 8.x or 9.x cluster to list indices, read mappings, and run Query DSL and ES|QL queries. Elastic has deprecated it in favor of the Agent Builder MCP endpoint. The vendor documents 5 tools, including list_indices, get_mappings, search and esql.

How do I add the Elasticsearch MCP server to an MCP client?

Elastic documents a Generic config; copy it from the Generic section of this page.

Does the Elasticsearch MCP server need authentication?

Yes, API key. Transport: stdio, Streamable HTTP. Status: Unlabelled, last checked October 17, 2026.

Sources

Last verified against 3 Elastic pages, then re-checked independently.

Newsletter

New MCP servers, the week they ship

One email per week. New official MCP servers, the coding tools that support them and how developers wire them up.