$ onnx run modnet --in-browserBackground Remover
Remove the background from a photo with deep learning: a portrait model that handles hair, and a light model for objects and products. The neural network runs in your browser with ONNX Runtime Web.
🔒 Your photos are processed on your device and never uploaded. The model downloads once and is cached.
How it works
- Pick a mode: "Person" for portraits and profile photos, "Object" for products and things.
- Choose a photo. The first time, the model downloads once and takes a few seconds; after that it loads from your browser's cache.
- Pick a new background (transparent, white, a color or blurred) and save the result as a PNG.
Frequently asked questions
Are my photos uploaded anywhere?
No. The neural network runs inside your browser and the photo never leaves your device. The only thing fetched from the server is the model itself.
Why is "Person" mode more accurate than "Object" mode?
The Person model is trained specifically on portraits and separates hair and edges precisely. For objects, the more accurate models are over 170 MB and very slow on a phone, so Object mode uses a 5 MB model that is fast but can make mistakes on cluttered photos.
Why is it slow the first time?
The first time, the selected model (5 to 26 MB) is downloaded and cached in your browser. After that nothing is downloaded; processing takes one to two seconds per photo on a laptop and a little longer on a phone.