Hugging Face

v1.0.0Data Science & MLstable

A Model Context Protocol server that provides Claude and other LLMs with read-only access to Hugging Face Hub APIs, enabling interaction with models, datasets, spaces, papers, and collections through natural language.

hugging-face-mcp-servermcpai-integration
Share:
240
Stars
0
Downloads
0
Weekly
0/5

What is Hugging Face?

Hugging Face is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to model context protocol server that provides claude and other llms with read-only access to hugging face hub apis, enabling interaction with models, datasets, spaces, papers, and collections through na...

A Model Context Protocol server that provides Claude and other LLMs with read-only access to Hugging Face Hub APIs, enabling interaction with models, datasets, spaces, papers, and collections through natural language.

This server falls under the Data Science & ML category on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • A Model Context Protocol server that provides Claude and oth

Use Cases

Access models, datasets, spaces, papers, and collections from Hugging Face Hub.
Query machine learning models and data resources via natural language.
Integrate Hugging Face ecosystem into AI workflows.
huggingface

Maintainer

LicenseMIT License
Languagetypescript
Versionv1.0.0
UpdatedMay 20, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

Manual Installation

npx hugging-face-mcp-server

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use Hugging Face

The Hugging Face MCP server gives AI assistants read-only access to the full Hugging Face Hub through the official MCP endpoint at huggingface.co/mcp, covering models, datasets, Spaces, papers, and collections. It supports both authenticated and unauthenticated access, with a Hugging Face token unlocking private repositories and higher rate limits. Data scientists and ML engineers use it to search and inspect Hub resources, discover Gradio-powered AI apps, and integrate Hub data into AI-driven research workflows.

Prerequisites

  • A Hugging Face account at huggingface.co (free)
  • A Hugging Face User Access Token from huggingface.co/settings/tokens (required for private repos and higher rate limits)
  • An MCP-compatible client — Claude Code, Claude Desktop, VS Code, or Cursor
  • No local build or npm install required — the server is hosted by Hugging Face
1

Create a Hugging Face access token

Go to huggingface.co/settings/tokens, click 'New token', give it a name, and select at minimum 'Read' scope. Copy the generated token.

2

Add the server to Claude Code via CLI

Use the Claude Code CLI to register the hosted MCP server with your token as an Authorization header.

claude mcp add hf-mcp-server -t http https://huggingface.co/mcp \
  -H "Authorization: Bearer YOUR_HF_TOKEN"
3

Configure available tools on Hugging Face

Visit huggingface.co/settings/mcp to select which Hub tools and Spaces are exposed through your MCP connection. This is a web UI provided by Hugging Face.

4

Verify the connection

Ask Claude to search for a model or dataset. A successful response confirms the server is connected and authenticated.

5

Optional: add to VS Code or Cursor config

For editor-based MCP clients, add the server as a URL-type entry with the Authorization header in your settings JSON.

Hugging Face Examples

Client configuration

VS Code or Cursor config for the Hugging Face MCP server using the hosted HTTP endpoint. Replace YOUR_HF_TOKEN with your actual token.

{
  "mcpServers": {
    "huggingface": {
      "url": "https://huggingface.co/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_HF_TOKEN"
      }
    }
  }
}

Prompts to try

Sample prompts to explore Hub models, datasets, Spaces, and papers.

- "Search Hugging Face for the most downloaded text-to-image models."
- "Find datasets on Hugging Face related to multilingual sentiment analysis."
- "Show me the top Spaces on Hugging Face for image generation."
- "Look up the Hugging Face paper on LLaMA 3 and summarize its key contributions."
- "List collections on Hugging Face tagged with 'diffusion models'."
- "What are the newest models fine-tuned on code generation tasks?"

Troubleshooting Hugging Face

Requests return 401 Unauthorized

Verify your token is correct and has at least Read scope. Go to huggingface.co/settings/tokens, regenerate the token if needed, and update your MCP config header with the new value.

Private repositories or gated models are not accessible

Ensure your token has the appropriate scopes for the resources you need. For gated models, you must also accept the model's license on the Hugging Face website before access is granted.

The server times out or returns no results

The default HF_API_TIMEOUT is 12.5 seconds. Heavy queries may exceed this. Try narrowing your search query. Also confirm that huggingface.co is reachable from your network — some corporate networks block it.

Frequently Asked Questions about Hugging Face

What is Hugging Face?

Hugging Face is a Model Context Protocol (MCP) server that model context protocol server that provides claude and other llms with read-only access to hugging face hub apis, enabling interaction with models, datasets, spaces, papers, and collections through natural language. It connects AI assistants to external tools and data sources through a standardized interface.

How do I install Hugging Face?

Follow the installation instructions on the Hugging Face GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.

Which AI clients work with Hugging Face?

Hugging Face works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is Hugging Face free to use?

Yes, Hugging Face is open source and available under the MIT License license. You can use it freely in both personal and commercial projects.

Browse More Data Science & ML MCP Servers

Explore all data science & ml servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "hugging-face-mcp-server": { "command": "npx", "args": ["-y", "hugging-face-mcp-server"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use Hugging Face?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides