Free Bokeh Effect Online: AI Portrait Blur Without Photoshop
How AI depth estimation creates a realistic bokeh blur from a single photo — no DSLR, no Photoshop, no subscription. Includes tips for best results on portrait and headshot photos.
Free Bokeh Effect Online: AI Portrait Blur Without Photoshop
Bokeh is the aesthetic quality of the out-of-focus blur in a photograph. DSLRs achieve it naturally with wide apertures and long focal lengths. Phones with Portrait mode simulate it using depth sensors. And now, AI can estimate depth from a single photo and apply a convincing blur to anything behind your subject — no camera upgrade required.
How It Works
NSS Portrait Blur uses Depth Anything Small — a 25MB vision transformer that estimates per-pixel depth from a single image. Pixels the model considers "far" receive progressively more blur; "near" pixels remain sharp.
The processing pipeline:
- Your photo is sent to a Web Worker
- The depth model runs locally via WebAssembly (or WebGPU if available)
- A depth map is generated: 0 = very close, 1 = very far
- A Gaussian blur is applied to the full image
- Sharp and blurred versions are composited per-pixel based on depth
All of this happens in your browser. Your photo never leaves your device.
Step by Step
1. Open Portrait Blur
Go to /portrait-blur. No signup, no account.
2. Upload your photo
Drag any portrait photo onto the drop zone. PNG, JPG, WebP, and HEIC all work. The AI downloads once (~25MB) and is cached for future use.
3. Adjust the controls
Three sliders control the result:
| Slider | Effect |
|---|---|
| Blur strength | How much blur is applied to the background (2–40px) |
| Foreground threshold | The depth cutoff between sharp and blurred areas |
| Edge feather | How smoothly the transition blends (prevents hard cutlines) |
Changes apply in real time once the depth map is computed.
4. Download
Download as PNG. The original photo dimensions are preserved.
Tips for Best Results
Outdoor photos work best. Clear depth separation between subject and background — a person in front of a garden, building, or natural landscape — gives the depth model the most signal to work with.
Raise the feather if you see hard lines. The default feather of 0.12 suits most photos. If you see a visible line between the sharp foreground and blurred background, increase feather to 0.20–0.25.
Lower the threshold if the blur cuts into the subject. If parts of your subject appear blurred, the threshold may be too high. Try 0.35–0.40 to push the foreground boundary closer.
Not a replacement for masking. The depth approach is approximate. Complex foregrounds (hair, glasses, transparent clothing) will have some imperfection at the edges. For pixel-precise cutouts, use the Image Background Remover with the brush tool instead.
When to Use Portrait Blur vs Background Removal
| Goal | Best tool |
|---|---|
| Add bokeh blur, keep original background visible | Portrait Blur |
| Remove background completely (transparent PNG) | Image Background Remover |
| Blur video background | Video Editor (blurred original mode) |
| Blur live webcam background | Live Camera BG Removal |
Supported Photo Types
- Portrait and headshot photos
- Outdoor scenes with clear foreground subjects
- Product photos with depth (raised objects on a table)
- Architectural shots
Less suited to:
- Flat lay product photos (no depth separation)
- Macro photography (very shallow depth of field makes the depth model less reliable)
- Low-resolution images under 500px
Related Tools
- Image Background Remover — full background removal with edge refinement
- Live Camera BG Removal — real-time blur for webcam
- Video Background Remover — remove or blur backgrounds in video clips