ComfyUI-HuggingFace integra perfettamente l'enorme repository di modelli HuggingFace direttamente in ComfyUI, permettendoti di cercare, scaricare e organizzare modelli AI senza lasciare il tuo workflow.
- Full HuggingFace Integration: Search HuggingFace's entire model library directly from ComfyUI
- Smart Filtering: Filter by model types (LoRA, Checkpoints, Diffusers, etc.)
- Base Model Filtering: Filter by SD 1.5, SDXL, Pony, and other base models
- Multiple Sort Options: Sort by downloads, likes, newest, or relevancy
- NSFW Support: NSFW content enabled by default (can be disabled)
- Real-time Results: Instant search results with model previews
- Dual Download Modes:
- Single Files: Download specific model files with
hf_hub_download - Full Repos: Download entire repositories with
snapshot_download(perfect for Diffusers)
- Single Files: Download specific model files with
- Automatic Type Detection: Smart categorization of models (checkpoints, LoRAs, etc.)
- Metadata Preservation: Downloads include model cards, descriptions, and statistics
- Resume Support: Resume interrupted downloads
- Multi-connection Downloads: Faster downloads with parallel connections
- Automatic Organization: Models saved to correct ComfyUI directories
- Custom Filename Support: Rename models during download
- Preview Images: Download and display model thumbnails
- Version Control: Track model versions and updates
- Download History: View and manage download history
- Pure huggingface_hub: Uses official
huggingface_hublibrary exclusively - No REST API Dependencies: Eliminates unreliable API calls
- Robust Error Handling: Graceful fallbacks for missing information
- Private Repository Support: Access private models with API tokens
- Clean Error Messages: User-friendly notifications without scary errors
- Open ComfyUI Manager
- Search for "ComfyUI-HuggingFace"
- Click Install
cd ComfyUI/custom_nodes
git clone https://github.com/huchukato/ComfyUI-HuggingFace.git- Start ComfyUI with ComfyUI-HuggingFace installed
- Access the Panel: Click the HuggingFace button in the top-right area
- Search Models: Use the search bar with filters and sorting options
- Preview Models: Click on any model to see details and preview
- Download: Click the download button to save models locally
- Use in ComfyUI: Models appear automatically in ComfyUI nodes
- Environment Variable:
HUGGINGFACE_API_KEY - In-App Settings: Enter token in ComfyUI-HuggingFace settings
- Benefits: Higher rate limits, access to private models
- Setting: Custom download directory
- Format:
<global_root>/<model_type> - Example:
/runpod-volume/ComfyUI/checkpoints - Default: Uses standard ComfyUI paths when empty
| Type | Description | Directory |
|---|---|---|
| Checkpoints | Main model files (.safetensors, .bin) | checkpoints/ |
| LoRAs | Low-Rank Adaptation models | loras/ |
| Diffusers | Complete diffusion pipelines | diffusers/ |
| Text Encoders | CLIP and encoder models | text_encoders/ |
| VAEs | Variational Autoencoders | vae/ |
| Embeddings | Text embedding models | embeddings/ |
| ControlNet | Control models | controlnet/ |
| IP-Adapters | Image adapter models | ip_adapters/ |
| Custom | Any model type from HuggingFace | User-defined |
- huggingface_hub: Official HuggingFace Python library
- snapshot_download: For complete repository downloads
- hf_hub_download: For single file downloads
- ModelCard: For reading model metadata and descriptions
- HfApi: For searching and listing models
POST /api/huggingface/search- Model search with filtersPOST /api/huggingface/get_model_details- Model informationPOST /api/huggingface/download- Initiate downloadsGET /api/huggingface/base_models- Available base modelsPOST /api/huggingface/cancel- Cancel downloadsGET /api/huggingface/download_status- Download progressGET /api/huggingface/history- Download historyGET /api/huggingface/model_dirs- Available model directories
- Primary: Use
huggingface_hubfunctions directly - Fallback 1: Try API calls for additional metadata
- Fallback 2: Return minimal information without errors
- UI: Show user-friendly messages instead of scary errors
This is a complete rewrite of Civicomfy with HuggingFace integration:
- โ Replaced Civitai API with HuggingFace API
- โ Updated URL parsing for HF model structure
- โ Maintained clean UI/UX from original
- โ Added HF-specific features (repo downloads, model cards)
- โ Improved error handling and user experience
- โ Removed REST API dependencies for reliability
- ๐ More Reliable: Official
huggingface_hublibrary - ๐ฏ More Models: Access to entire HuggingFace repository
- ๐ Smart Downloads: Repo vs single file detection
- ๐ก๏ธ Better Security: No more direct URL construction
- ๐จ Cleaner UI: No scary error messages
Contributions are welcome! Please feel free to submit a Pull Request.
- Additional Model Types: Support for new model formats
- UI/UX Improvements: Better user interface and experience
- Performance Optimizations: Faster downloads and search
- Bug Fixes: Testing and issue resolution
- Documentation: Improving guides and examples
git clone https://github.com/huchukato/ComfyUI-HuggingFace.git
cd ComfyUI-HuggingFace
# Install dependencies
pip install -r requirements.txt
# Test with ComfyUI- ComfyUI: Latest version recommended
- Python: 3.8+
- Memory: 4GB+ RAM recommended
- Storage: Sufficient space for model downloads
huggingface_hub>=0.20.0- HuggingFace integrationrequests>=2.25.0- HTTP requestsaiohttp- Async web server (ComfyUI)
HUGGINGFACE_API_KEY- For higher rate limits- Custom model directories - For organization
This project follows the same license as the original Civicomfy project.
- Civicomfy by MoonGoblinDev - Original inspiration and base
- HuggingFace - Amazing model repository and API
- ComfyUI Community - Feedback, testing, and support
- huggingface_hub - Official Python library
- Issues: Report bugs via GitHub Issues
- Features: Request features via GitHub Discussions
- Discord: Join the ComfyUI community
- Updates: Follow the repository for latest features
โญ If you find this useful, please give it a star on GitHub!
Made with โค๏ธ for the ComfyUI community
๐ฎ๐น Italian Documentation - Read the docs in Italian

