Skip to content
Docker Hub MCP Server

Docker Hub MCP Server

Added to Onei
4 views
Apache-2.0

Summary

Docker's official MCP server for Docker Hub — let an agent search images, read tags and metadata, and manage your repositories in natural language.

Features

  • Search Docker Hub images and repositories with live data
  • Read tags, metadata and repository details
  • Manage your own repositories with a Docker Personal Access Token
  • Tools generated from Docker Hub's OpenAPI specification
  • stdio and HTTP transports; HTTP is authenticated and fails closed by default
  • DNS-rebinding and CSRF protection via Host/Origin allow-lists
  • Works with Ask Gordon in Docker Desktop and the Docker CLI

Installation

Set up this MCP server in your favorite AI agent — copy a ready-made configuration below.

Any MCP-compatible agent

Most agents (Claude, Cursor, Windsurf, VS Code, and more) read a standard mcpServers configuration.

  1. Open your agent's MCP configuration file.
  2. Merge the snippet below into it, filling in the environment variables with your own values.
  3. Restart the agent — the "Docker Hub MCP Server" tools will be available.
{
  "mcpServers": {
    "docker-hub": {
      "command": "node",
      "args": [
        "/FULL/PATH/TO/hub-mcp/dist/index.js",
        "--transport=stdio"
      ],
      "env": {
        "HUB_PAT_TOKEN": "<your_docker_hub_pat>"
      }
    }
  }
}

Description

LLMs recommend container images badly. Docker Hub holds millions of repositories with wildly varying quality, maintenance and provenance, and a model working from training data alone will confidently suggest an image that is unofficial, abandoned, or wrong for the architecture. This server gives the agent the live catalogue instead.

What it exposes

Tools are generated from Docker Hub's OpenAPI specification, covering image and repository search, tag listings, image metadata and repository management. Unauthenticated it can query public Docker Hub content; supply a Docker Personal Access Token and it can also manage repositories belonging to that account.

Transports, and a security posture worth noting

It runs over stdio for local clients, or http when you need to reach it over a network. The HTTP transport is deliberately locked down and fails closed: it binds to loopback unless you pass --host, refuses to start without either a bearer token (MCP_AUTH_TOKEN) or an explicit opt-out, and rejects requests whose Host or browser Origin headers are not allow-listed. That matters because in HTTP mode every tool call is dispatched with the operator's Docker Hub PAT — anyone who can reach the port can act as that identity.

Setup

Clone the repository, npm install && npm run build, then point your client at dist/index.js. It is not published to npm, so there is no npx one-liner. It also plugs into Ask Gordon, the assistant built into Docker Desktop and the Docker CLI, via a gordon-mcp.yml file.

Requires Docker and Node.js 22 or newer.

Related MCP Servers

New

Qase test management over MCP: 36 task-oriented tools for cases, runs, results, defects and QQL search, hosted at mcp.qase.io or self-run with your own API token.

New

Arm's official MCP server for porting and tuning software on Arm — semantic docs search, codebase migration scanning, container architecture checks and LLVM-MCA assembly analysis.

New

Official AntV MCP server that turns a description of your data into a rendered chart — 26 visualization types from bar and line to sankey, mind-map, fishbone and geographic maps.

MCP: Headroom

by Headroom Labs

New

Context-compression MCP server that shrinks tool outputs, logs, files and RAG chunks before they reach the model, cutting 60-95% of tokens on JSON payloads.

Browse all MCP servers →