This tool uses IMG.LY's open-source background removal library, which runs an IS-Net segmentation model with ONNX Runtime and WebAssembly in your browser. The model looks at a 1024 x 1024 version of the photo and estimates, for every pixel, how likely it is to belong to the main subject.
That rough mask is then refined at your photo's full resolution: an edge-aware filter uses the original photo to sharpen the outline, small stray spots are removed, and background colour that bleeds into semi-transparent edges (a green fringe around hair against grass, for example) is subtracted. On GPUs that support it the model runs on the graphics card; otherwise it runs on the processor.