Running BiRefNet background removal in a Web Worker (and the CSP bug that almost bit us)
javascript
dev.to
Most online background removers make you upload your photo to a server, wait in a queue, and then either cap the export resolution or slap a watermark on it unless you pay for credits. When I built the background remover for Imagier, I wanted the whole pipeline to stay on the user's device. No uploads, no rate limits, and full PNG output right out of the box. Running a modern segmentation model like BiRefNet in the browser with ONNX Runtime Web is surprisingly doable now, but a few production