Background Blur: AI Portrait-Style Effect
Apply a DSLR-style background blur to any photo. The same U2Net AI model that powers our background remover detects the main subject in the image, then blurs everything outside the subject while keeping it sharp. Adjustable blur amount from subtle to strong. Runs entirely in your browser; the image never leaves your device.
Drop an image here, or click to choose
The AI subject detection runs in your browser. Nothing leaves your device.
About AI background blur
How does the AI work?
The tool uses U2Net, a deep neural network for salient object detection. It analyses the image and produces a "saliency map" that identifies which pixels belong to the main subject (high values) and which belong to the background (low values). The tool then blurs the original image and composites the sharp subject pixels back on top, using the saliency map as a blending mask.
What makes a good source photo?
Clear subject against a contrasting background works best. Portraits with the subject filling at least a third of the frame. Product shots on simple surfaces. Pets against a plain wall. The model struggles with: very small subjects (less than 5 percent of frame), complex hair against busy backgrounds, transparent or wispy materials, and images where subject and background colors are very similar.
Blur amount guidance
5-10 px is a subtle blur that softens distractions without obvious effect. 15-25 px is a moderate "portrait mode" feel, common in modern phone cameras. 30-40 px is strong, like a wide-aperture DSLR portrait at 85mm f/1.4. Above 40 px the background becomes abstract bokeh, which can look artistic but loses scene context.
Real bokeh vs computational blur
A DSLR with a wide-aperture lens produces optical bokeh: the actual lens elements project out-of-focus light points as soft circles of varying brightness, with specific shapes determined by aperture blades and lens design. Computational blur (this tool and most phone "portrait mode" features) applies a uniform Gaussian blur to all background pixels. The two look similar at small sizes but differ in subtle ways at high resolutions and very wide aperture equivalents.
Subject edge quality
The U2Net mask has a small gradient at the subject boundary, which causes a few pixels of blend between the sharp subject and the blurred background. This gradient looks natural because real DSLR bokeh has the same property (it follows the focus plane). Hair strands, complex outlines, and very fine details may show small artifacts where the AI mask is imperfect.
Comparison with phone portrait mode
Modern phones (iPhone, Pixel, Galaxy) use both AI segmentation and depth sensors (LiDAR, dual-camera parallax) to produce excellent portrait-mode results. This tool only uses 2D AI segmentation, so it is slightly less accurate at subject edges, especially for hair. The advantage of this tool: it works on any existing photo (including old ones taken without portrait mode) on any device with a modern browser.
The U2Net model
U2Net is an open-source salient object detection model published in 2020. It uses a U-shaped neural network architecture (hence "U2Net") with nested encoders and decoders. The version this tool uses is U2NetP, a lightweight variant about 4.6 MB in size that runs efficiently in browsers. The full U2Net (about 175 MB) is more accurate but too large for browser use.
Licenses and privacy
The tool uses onnxruntime-web (MIT license) and U2Net (Apache 2.0 license), both fully open-source and commercially usable. The model file is hosted on our server and downloads on first use only. All inference, blur, and compositing happen in your browser. We never see your images. You can verify this in browser developer tools by checking the network tab.
Combining with other tools
Blur the background here, then crop with our image cropper to focus the composition. Or watermark the blurred result for sharing. The browser-based pipeline lets you chain operations without uploading to any server, which preserves both quality and privacy.
It uses the same U2Net AI model as our background remover. The model identifies the main subject in the image, then the tool keeps the subject sharp and applies a Gaussian blur to everything else. Both steps happen in your browser; nothing is uploaded.
10-20px is a moderate, natural-looking portrait blur. 20-40px gives a strong DSLR-style bokeh effect. Above 40px looks dreamlike but can lose detail context. Start at 20 and adjust with the slider until the look matches what you want.
Sometimes. The U2Net model is best at single-subject detection. For two or three closely grouped people, it usually treats them as one subject. For widely separated multiple subjects, it may only detect the most prominent. Re-run if the result is not satisfactory.
U2Net is one of the best free salient object detection models available. It is highly accurate for portraits, product shots, and clear subjects against simple backgrounds. It struggles with: complex hair (fine flyaway strands), transparent or wispy materials, and busy backgrounds with similar colors to the subject.
No. The model runs on the CPU using WebAssembly via onnxruntime-web. Inference takes a few seconds on most modern devices. On mobile, it may take 5 to 15 seconds for larger images. The first run downloads the AI model (about 4.6 MB).
Yes. U2Net is released under the Apache 2.0 license and is freely usable in commercial projects. The model file (u2netp.onnx) is self-hosted from the Gizmoop server and downloads once per browser visit. We chose this model carefully to avoid AGPL or non-commercial restrictions.
Set the blur slider to 0 and the original image comes through unchanged (well, re-encoded to PNG). For the literal original file, just use the file you uploaded.
The AI mask has a small gradient at the boundary, which causes a few pixels of blend between the sharp subject and the blurred background. This actually looks natural because real DSLR bokeh has the same property at depth-of-field edges. If you need a hard edge, use our background remover and compose manually.
Modern phone portrait modes use depth sensors plus AI to produce excellent results. This tool only uses AI on a 2D image, which is slightly less accurate but works on any photo from any source, not just photos taken with a depth-capable camera. For best results, use phone portrait mode at capture time; use this tool for older photos that lack depth data.
Not directly. The tool keeps the AI-detected subject sharp. To blur the foreground (subject) and keep the background sharp, use our background remover to extract the subject, blur the extracted subject in a separate step, and recomposite. We may add a foreground-blur toggle in a future update.
The AI works on a downscaled 320x320 internal representation, so large images do not need exceptional clarity to detect the subject well. For best detection, the subject should be clearly visible (not tiny relative to the frame) and reasonably well-lit. Images larger than 4000 pixels per side may slow down processing.
Yes. The image, the AI inference, and the final blurred output all happen in your browser. The model file downloads from our server on first use (no information sent back), and the runtime (onnxruntime-web) loads from a CDN. Your images never go to any server.
onnxruntime-web is MIT-licensed. The U2Net model is Apache 2.0. Both are fully usable for commercial work. We specifically avoided the AGPL-licensed @imgly/background-removal library and the non-commercial RMBG-1.4 model in favor of license-safe alternatives.