HuggingFace MCP Server

HuggingFace MCP server provides AI assistants with access to the model hub — search 1M+ models, discover datasets, explore Spaces, read papers, and fetch documentation directly through MCP.

June 10, 2026
MCP ServerAI & ML ToolsHuggingFace MCP Server
Official HuggingFace

Overview

The HuggingFace MCP Server is the official Model Context Protocol integration for the HuggingFace Hub — the world's largest collection of machine learning models, datasets, and demos. It lets AI assistants search and discover models, explore datasets, browse Spaces, read ML papers, and fetch up-to-date documentation without leaving the conversation.

Official Verified Server:

Developed and maintained by HuggingFace. Verified on Smithery. Available as a remote MCP server with OAuth authentication.

Key Features

🤖

Model Discovery

Search 1M+ models by task, framework, license, and popularity with detailed metadata

📊

Dataset Explorer

Find and inspect datasets across NLP, vision, audio, tabular, and multimodal domains

🚀

Spaces Discovery

Explore interactive ML demos and applications deployed as HuggingFace Spaces

📝

Research Papers

Search daily ML papers, filter by upvotes, and access paper details with citations

📖

Documentation Search

Search and fetch HuggingFace library docs (Transformers, Diffusers, Datasets, PEFT) live

🎨

Image Generation

Generate images directly through hosted Spaces using Gradio-powered models

Available Tools

Quick Reference

ToolPurposeCategory
hub_repo_searchSearch models, datasets, and SpacesDiscovery
hub_repo_detailsGet full metadata for any HF repositoryDiscovery
model_searchSearch specifically for models by taskModels
dataset_searchSearch specifically for datasetsDatasets
paper_searchSearch daily ML papers with filtersResearch
space_searchSearch interactive demos and appsSpaces
hf_doc_searchSearch HuggingFace library documentationDocs
hf_doc_fetchFetch specific documentation pagesDocs
hf_whoamiCheck authenticated user identityAuth

Detailed Usage

hub_repo_search

Search across models, datasets, and Spaces with filters for task type, framework, license, and sort order.

{
  "query": "text-to-image diffusion model",
  "type": "model",
  "task": "text-to-image",
  "sort": "likes",
  "limit": 10
}
hub_repo_details

Get full metadata for a specific repository including README, model card, tags, downloads, and files.

{
  "repoId": "meta-llama/Llama-3.1-8B-Instruct"
}
paper_search

Search the daily AI/ML papers feed with filters by date range and minimum upvotes.

{
  "query": "mixture of experts",
  "dateRange": "lastWeek",
  "minUpvotes": 10
}
hf_doc_search

Search across HuggingFace library documentation (Transformers, Diffusers, Datasets, PEFT, TRL) for up-to-date API references and guides.

{
  "query": "pipeline text generation parameters",
  "library": "transformers",
  "limit": 5
}

Installation

{
  "mcpServers": {
    "huggingface": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-remote",
        "https://mcp.huggingface.co"
      ]
    }
  }
}

The remote server handles OAuth authentication — you'll be prompted to log in to your HuggingFace account on first use.

HuggingFace Token:

Generate a token at huggingface.co/settings/tokens. A read-only token is sufficient for search and documentation tools. Write access is required for Spaces and image generation.

Example Use Cases

  • Model Selection: Ask your AI assistant to find the best open-source LLM for your use case, comparing licenses, context windows, and performance benchmarks
  • Research Discovery: Stay current with daily ML papers filtered by your domain of interest
  • Documentation Lookup: Fetch exact Transformers or Diffusers API references without leaving your IDE
  • Dataset Search: Find training datasets by task, language, and size with licensing details
  • Demo Exploration: Discover interactive Spaces for a specific technology to understand capabilities before implementation

Security

  • OAuth authentication via HuggingFace account — no API keys in config files
  • Read-only tools for search and metadata require no special permissions
  • Fine-grained token scopes for write operations (read, write, inference)
  • Remote server handles credential management and token refresh
  • HTTPS encryption for all communication

Sources