Lightning-fast AI background removal CLI tool for Mac, Linux, and Windows
- 🚀 Blazing Fast - Process images in seconds using state-of-the-art AI
- 🔒 Private & Secure - Runs entirely locally on your machine
- 🎯 High Quality - Produces clean cutouts with excellent edge handling
- 📦 Batch Processing - Process entire folders with a single command
- 🔧 Zero Config - Works out of the box with sensible defaults
- 🍎 Mac Optimized - Native macOS support with pipx installation
# Remove background from a single image
$ quickbg photo.jpg
Processing: photo.jpg
Saved: photo-nobg.png
# With custom output
$ quickbg product.png -o cleaned.png
# Batch process a folder
$ quickbg -b ./productPhotos/
Found 25 image(s) to process
Output directory: ./productPhotos/nobg
--------------------------------------------------
[1/25] img_001.jpg... OK
[2/25] img_002.jpg... OK
...
--------------------------------------------------
Done! 25/25 images processed successfully| Before | After |
|---|---|
# Install pipx if you don't have it
brew install pipx
# Install QuickBG
pipx install quickbgpipx install quickbgpipx install quickbgpip install quickbggit clone https://github.com/jschof1/quickbg.git
cd quickbg
pip install -e .# Basic usage (saves as filename-nobg.png)
quickbg input.jpg
# Specify output filename
quickbg input.png -o result.png
# Enable alpha matting for better edges (slower)
quickbg input.jpg --alpha-matting# Process all images in a folder
quickbg -b ./photos/
# Specify output directory
quickbg -b ./photos/ -o ./output/
# With alpha matting
quickbg -b ./photos/ -a- Input: JPG, JPEG, PNG, WebP, BMP, TIFF, TIF
- Output: PNG (with transparency)
| Flag | Description |
|---|---|
input |
Input image file or directory |
-o, --output |
Output file or directory path |
-b, --batch |
Batch mode: process all images in directory |
-a, --alpha-matting |
Enable alpha matting for better edge refinement |
-v, --version |
Show version number |
-h, --help |
Show help message |
# Clone the repository
git clone https://github.com/jschof1/quickbg.git
cd quickbg
# Create virtual environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Install in development mode
pip install -e ".[dev]"
# Run tests
pytest
# Format code
black src/ tests/
# Lint code
ruff check src/ tests/pytest tests/ -vContributions are welcome! Please read our Contributing Guidelines first.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
Made with ❤️ by Jack Schofield
