A newer version of the Gradio SDK is available:
6.1.0
title: Free Background Remover
emoji: πΌοΈ
colorFrom: blue
colorTo: purple
sdk: gradio
sdk_version: 4.44.1
app_file: app.py
pinned: false
license: apache-2.0
short_description: Background removal tool, multiple AI models-no login needed
tags:
- computer-vision
- image-processing
- rembg
- background-removal
- u2net
- isnet
- ai-tools
π¨ Advanced Background Remover v2.9
A powerful, free web-based tool for professional background removal from images. No login required, no watermarks, no paywalls - just upload and download!
β¨ Features
π― Smart Background Removal - Advanced AI models for precise edge detection
π¨ Custom Backgrounds - Replace with solid colors or keep transparent
π€ Multiple AI Models - Choose the best model for your specific use case
βοΈ Alpha Matting - Enhanced edge quality for professional results
π Specialized Models - Dedicated models for humans, anime, and clothing
π± Easy to Use - Simple drag-and-drop interface
πΎ Instant Download - Get your processed image immediately
π€ Available AI Models
| Model | Best For | Size | Quality |
|---|---|---|---|
| u2net | General use cases (recommended) | Standard | High |
| isnet-general-use | New general model with improved accuracy | Standard | Very High |
| isnet-anime | Anime characters and illustrations | Standard | Excellent |
| u2net_human_seg | Human portraits and people | Standard | Excellent |
| u2net_cloth_seg | Clothing and fashion items | Standard | High |
| silueta | Fast processing (reduced size) | 43MB | Good |
| u2netp | Lightweight, faster processing | Small | Good |
| unet | Basic background removal | Small | Standard |
π Quick Start
Online Usage (Recommended)
Visit the Hugging Face Space and start removing backgrounds instantly!
Local Installation
Clone the repository
git clone https://github.com/your-username/background-remover.git cd background-removerInstall dependencies
pip install -r requirements.txtRun the application
python app.py
π‘ How to Use
- Upload Image - Drag and drop or click to select your image
- Choose Options:
- π¨ Select background color (or keep transparent)
- π€ Pick the best AI model for your image type
- βοΈ Enable advanced options if needed
- Process - Click "Submit" and wait a few seconds
- Download - Right-click the result to save your image
βοΈ Advanced Options
- π― Alpha Matting: Improves edge quality for hair and fine details
- π§ Post-Process Mask: Additional refinement of the cutout
- ποΈ Mask Only: Export just the selection mask
- π¨ Custom Colors: Any hex color for background replacement
π― Use Cases
- E-commerce: Product photos with clean backgrounds
- Social Media: Profile pictures and content creation
- Design Work: Graphics and marketing materials
- Photography: Portrait enhancement and compositing
- Art & Animation: Character extraction and manipulation
π§ API Usage Example
from PIL import Image
from rembg import remove, new_session
# Basic usage
input_image = Image.open('input.jpg')
output_image = remove(input_image)
output_image.save('output.png')
# Advanced usage with specific model
session = new_session('u2net_human_seg')
output_image = remove(input_image, session=session)
output_image.save('output.png')
# With alpha matting for better quality
output_image = remove(
input_image,
alpha_matting=True,
alpha_matting_foreground_threshold=270,
alpha_matting_background_threshold=20,
alpha_matting_erode_size=11
)
output_image.save('output.png')
π Model Performance
| Model | Speed | Quality | Best For |
|---|---|---|---|
| silueta | β‘β‘β‘ | βββ | Quick processing |
| u2netp | β‘β‘ | ββββ | Balanced |
| u2net | β‘ | βββββ | High quality |
| isnet-general-use | β‘ | βββββ | Best overall |
| isnet-anime | β‘ | βββββ | Anime/illustrations |
π€ Contributing
Contributions are welcome! Here's how you can help:
- π Report bugs and issues
- π‘ Suggest new features
- π§ Submit pull requests
- π Improve documentation
- β Star the repository if you find it useful!
π Requirements
gradio>=4.44.1
rembg>=2.0.50
Pillow>=10.0.0
numpy>=1.24.0
π Alternative Tools
If you need more features, consider these alternatives:
- Adobe Express Background Remover (requires Adobe account)
- Remove.bg (limited free usage)
π License
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
π Acknowledgments
- rembg - The powerful Python library powering the background removal
- Gradio - The framework making this tool accessible to everyone
- Hugging Face - For hosting this free tool
π References
This Space is built using the rembg library, which leverages the following research papers:
U2-Net: Going Deeper with Nested U-Structure for Salient Object Detection
@article{qin2020u2net, title={U2-Net: Going Deeper with Nested U-Structure for Salient Object Detection}, author={Qin, Xuebin and Zhang, Zichen and Huang, Chenyang and Dehghan, Masood and Zaiane, Osmar R and Jagersand, Martin}, journal={arXiv preprint arXiv:2005.09007}, year={2020} }[IS-Net: Deep Interactive Segmentation Network])(https://arxiv.org/abs/2203.03041)
@article{qin2022isnet, title={Highly Accurate Dichotomous Image Segmentation}, author={Qin, Xuebin and Fan, Deng-Ping and Huang, Chenyang and Di, Deng and Zhang, Zichen and Zaiane, Osmar R and Jagersand, Martin and Van Gool, Luc}, journal={arXiv preprint arXiv:2202.13085}, year={2022}
}
β Star this repository if you find it useful! β
Made with β€οΈ for the open-source community