Rembg
Background-removal tool you run as a CLI, Python library, HTTP server or Docker container.
Quick answer
Rembg is a background-removal tool you run as a CLI, Python library, HTTP server or Docker container, listed under Image & media generation. A typical small-business use: cut out product photos for a web store or marketplace listings in bulk. The project publishes no official RAM figure, so we do not estimate a monthly server cost. License: MIT (model weights under their own licenses), which allows internal business use.
Last updated · facts verified against official docs on · sources
Activity data comes from GitHub and was last refreshed Nov 2, 2026.
What is Rembg?
Rembg removes image backgrounds with local ONNX segmentation models such as BRIA RMBG-2.0, BiRefNet, U2-Net, IS-Net and SAM. It runs on CPU by default, with optional NVIDIA CUDA or AMD ROCm acceleration, and works as a command-line tool (single files, folders, watch mode or video frames from FFmpeg), a Python library, or an HTTP server with an API and a small Gradio web UI. Models download on first use and then run offline; two optional cloud backends send images to third-party APIs only if you pick them.
Where it fits in a 10–200 person business
- Cut out product photos for a web store or marketplace listings in bulk
- Add a background-removal endpoint to an internal design or e-commerce tool
- Watch a folder and automatically produce transparent PNGs for the marketing team
These use cases are our editorial suggestions, not claims made by the project.
Can a business use Rembg? (license)
| License | MIT (model weights under their own licenses) |
|---|---|
| Type | Permissive: MIT / Apache-2.0: use, modify and sell with few obligations. |
| Internal business use | Allowed under the license text |
| What to watch | The rembg code is MIT: free for internal and commercial use. Each model has its own license; the default BRIA RMBG-2.0 model requires a paid agreement for commercial use, so pick a different model for business work or license it. |
This is a plain-English summary of the license text, not legal advice. Third-party models you run with it have their own licenses.
Data & compliance: does Rembg phone home?
| Telemetry (usage data sent to the vendor) | Not documented |
|---|---|
| Other calls home by default (updates, marketplaces, default cloud services) | Yes, by default Local models are downloaded on first use; the optional withoutbg and atlascloud backends send images to third-party servers when selected. |
| Single sign-on (OIDC / SAML / LDAP) | Not documented |
| Audit log | Not documented |
| Role-based access control (RBAC) | Not documented |
| Data residency / GDPR notes from the project | Not documented |
Checked against the project's own docs and repository on . "Not documented" means we could not find the answer in official sources; it does not mean the feature is missing or that no data is sent. Third-party services you connect (model APIs, vector databases, search engines) have their own data policies. Compare all apps.
What hardware does Rembg need?
The project does not publish a minimum CPU/RAM figure, so we leave the official value blank rather than guess.
GPU: Optional. CPU is the default backend; NVIDIA (onnxruntime-gpu with CUDA and cuDNN) and AMD (onnxruntime-rocm) are supported.
No CPU or RAM figures are published. Requires Python 3.11 to 3.13. The CPU Docker image is about 1.6 GB and the self-built CUDA image about 11 GB, without models; the default model is about 1.02 GB.
How much does it cost to host Rembg per month?
The project publishes no RAM figure we could verify, so we do not estimate a cost.
How to deploy Rembg
Method: pip (HTTP server); Docker image for the CLI
pip install "rembg[cpu,cli]"
rembg s --host 0.0.0.0 --port 7000 --log_level info
# API docs at http://localhost:7000/api ; add --no-ui to drop the Gradio UI
# CLI via Docker: docker run -v .:/data danielgatis/rembg i /data/input.png /data/output.png From the official instructions: github.com/danielgatis/rembg#readme. Always check the source for the current version before you run it.
Known gotchas when self-hosting Rembg
- The default model, BRIA RMBG-2.0, is released under a BRIA license that requires a paid agreement for commercial use. Pass -m with another model (for example u2net or a BiRefNet model) and check that model's own license. source
- Models are downloaded on first use to ~/.rembg/models/, so the first run needs internet access; pre-download or persist that folder for offline servers and containers. source
- CUDA acceleration needs cuDNN, so there is no ready-made GPU image: you build Dockerfile_nvidia_cuda_cudnn_gpu yourself (about 11 GB) and need the NVIDIA Container Toolkit. source
- The withoutbg and atlascloud model options are cloud APIs that upload your images to those companies' servers; stick to local models for private images. source
Alternatives in Image & media generation
- Stable Diffusion web UI (AUTOMATIC1111) Classic Gradio web interface for Stable Diffusion with txt2img, img2img, inpainting, upscaling and a large extension ecosystem. Compare Rembg vs Stable Diffusion web UI (AUTOMATIC1111)
- ComfyUI Node-based engine for generating images, video, 3D and audio with open models. Compare ComfyUI vs Rembg
- MoneyPrinterTurbo Turns a topic or keyword into a finished short video with script, stock footage, voice-over and subtitles. Compare MoneyPrinterTurbo vs Rembg
- InvokeAI Creative studio for AI image (and video) generation with canvas, layers and workflows. Compare InvokeAI vs Rembg
Rembg FAQ
How much RAM does Rembg need?
Rembg does not publish an official RAM figure, so we do not state one. No CPU or RAM figures are published. Requires Python 3.11 to 3.13. The CPU Docker image is about 1.6 GB and the self-built CUDA image about 11 GB, without models; the default model is about 1.02 GB.
Does Rembg need a GPU?
Optional. CPU is the default backend; NVIDIA (onnxruntime-gpu with CUDA and cuDNN) and AMD (onnxruntime-rocm) are supported.
How much does it cost to self-host Rembg?
The software is free to download. The project publishes no official RAM figure, so we do not estimate a monthly server cost.
Is Rembg free for commercial use?
Rembg is licensed under MIT (model weights under their own licenses) (Permissive). Internal business use is allowed under the license text. The rembg code is MIT: free for internal and commercial use. Each model has its own license; the default BRIA RMBG-2.0 model requires a paid agreement for commercial use, so pick a different model for business work or license it. This is a summary, not legal advice.
What are common problems when self-hosting Rembg?
The default model, BRIA RMBG-2.0, is released under a BRIA license that requires a paid agreement for commercial use. Pass -m with another model (for example u2net or a BiRefNet model) and check that model's own license. Models are downloaded on first use to ~/.rembg/models/, so the first run needs internet access; pre-download or persist that folder for offline servers and containers. CUDA acceleration needs cuDNN, so there is no ready-made GPU image: you build Dockerfile_nvidia_cuda_cudnn_gpu yourself (about 11 GB) and need the NVIDIA Container Toolkit. The withoutbg and atlascloud model options are cloud APIs that upload your images to those companies' servers; stick to local models for private images.
Is Rembg still maintained?
Yes, it is actively developed. Last commit: Nov 2, 2026. Latest release: v2.0.86 (Oct 21, 2026). Checked Nov 2, 2026.
How do I install Rembg?
The official method is pip (HTTP server); Docker image for the CLI. The exact commands are in the "How to deploy" section above and in the official instructions: https://github.com/danielgatis/rembg#readme
What are self-hosted alternatives to Rembg?
Other apps in Image & media generation: Stable Diffusion web UI (AUTOMATIC1111), ComfyUI, MoneyPrinterTurbo, InvokeAI.
Sources
- GitHub repository: github.com/danielgatis/rembg
- Official documentation, Hardware requirements, Deploy instructions: github.com/danielgatis/rembg#readme
- License text: github.com/danielgatis/rembg/blob/main/LICENSE.txt
- Gotcha 1, Gotcha 2, Gotcha 4: github.com/danielgatis/rembg#models
- Gotcha 3: github.com/danielgatis/rembg#usage-with-docker
- Hetzner Cloud pricing (cost estimate): www.hetzner.com/cloud/regular-performance
- GitHub stars, commits and releases: GitHub REST API, fetched
Facts on this page were checked against the project's own repository and docs on 2026-11-02. Spotted something out of date? Tell us.