Hugging Face · huggingface — Claude Code MCP server: features and setup
Search Hugging Face models, datasets, Spaces, papers and documentation from an AI coding client, or generate an image from a prompt.
no license 2,405 installs updated 2026-03-29
claude mcp add --transport http huggingface https://huggingface.run.toolsWhat Hugging Face does
The server lets an agent search model and dataset repositories, discover Spaces and machine learning papers, and retrieve repository details. Separate tools search Hugging Face and Gradio documentation, then fetch pages. Another tool creates an image from a prompt and generation settings.
It connects over HTTP and supports clients including Claude Code, Codex, Cursor and Gemini CLI. The hf_whoami tool explains how to authenticate; anonymous requests may be rate limited. Keep that limit in mind if your workflow makes repeated requests.
What it helps with
- find models and datasets by query
- retrieve details for a Hugging Face repository
- discover Spaces or machine learning papers
- search Hugging Face documentation
- generate an image from a text prompt
Example prompts for the agent
- Find Hugging Face models for image classification.
- Show details for the dataset
owner/dataset-name. - Generate an image from this description.
How to install Hugging Face
Platform CLI: remote server
claude mcp add --transport http huggingface https://huggingface.run.toolsPlatform CLI: remote server
codex mcp add hugging-face --url https://huggingface.run.toolsConfig file
{
"mcpServers": {
"hugging-face": {
"url": "https://huggingface.run.tools"
}
}
}Config file
{
"servers": {
"hugging-face": {
"type": "http",
"url": "https://huggingface.run.tools"
}
}
}Platform CLI: remote server
gemini mcp add -t http hugging-face https://huggingface.run.toolsStep by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about Hugging Face
How do I install Hugging Face in Claude Code?
Run claude mcp add --transport http huggingface https://huggingface.run.tools to add the server over HTTP.
What does the Hugging Face MCP server do?
It searches models, datasets, Spaces and research papers, retrieves repository details, and helps find documentation. It can also generate images from prompts.
Do I need to authenticate?
The hf_whoami tool provides instructions for connecting an account. Anonymous requests may be rate limited.
Similar MCP servers
All MCP servers for AI and ML →Hugging Face by other authors comes first.