v1.2.23 macOS 26+ Swift 6.3+ MIT 100% on-device
Background remover for macOS. Image in, image out — Apple Vision, on-device, scriptable.
$brew install Arthur-Ficial/tap/bgbgone
3 MB binary. No cloud. No account.
Mac app v0.3.4 Apple silicon
Rather have a window than a flag? Get the app.
The same on-device engine, in a native macOS window. Drop a folder, watch it process — end up with a folder of clean cutouts. Never touch a terminal.
01 · Live demo
Pick a subject. Pick an algorithm. See the real cut.
$ bgbgone red-panda.jpg --algo auto
person shows only where Vision finds a person — never faked.
02 · Receipts
Numbers, not adjectives.
| 81ms | per image |
| 12.3/s | throughput |
| 3MB | binary |
| 0net | network calls |
| 0$ | forever |
03 · Install
Install. Run.
Install
brew tap Arthur-Ficial/tap
brew install Arthur-Ficial/tap/bgbgone
From source: make install. macOS 26+, no Xcode.
Use
# default: writes photo_bgbgone.png next to input
$ bgbgone photo.jpg
# transparent PNG to stdout
$ bgbgone photo.jpg > cutout.png
# on a solid colour
$ bgbgone photo.jpg --bg color:white -o on-white.png
# on an image
$ bgbgone photo.jpg --bg image:beach.jpg -o beach.png
# pipe in
$ cat in.png | bgbgone > out.png
# batch a folder
$ bgbgone *.jpg --out-dir ./out/
# local HTTP API on 127.0.0.1:8787
$ bgbgone --server
05 · Flags
The whole surface.
Background
--bg color:<#hex|named|rgb:r,g,b>solid colour--bg image:<path>image file--bg-color <spec>shared solid colour field--bg-image <path>shared background image field--bg-fit cover|contain|tile|centerfit mode for image backgrounds
Matte / edge
--mask-onlyoutput the alpha mask only--channels rgba|alphafinalized image or alpha mask--feather <px>edge softening (default: 1)--threshold <0..1>mask binarisation--padding <px|N%>extra space around subject--crop-margin <1|2|4 values>API-style crop margins--croptight-crop to subject bbox--roi "x1 y1 x2 y2"region of interest, px or %--scale <10%..100%|original>scale subject on canvas--position <center|x% y%|original>place scaled subject--semitransparency true|falsekeep or harden semi-transparent pixels--shadowdrop shadow under cutout--shadow-type auto|drop|3D|car|noneshadow selector--shadow-opacity <0..100|auto>shadow darkness
Algorithm
--algo auto|vn-mask|person|saliencydefault: auto--type auto|person|product|car|animal|graphic|transportationtype hint
Multi-instance
--multione file per detected instance--instance-naming "{base}-{n}.{ext}"filename template ({n:NN})
Output
--to, --format png|jpg|zip|heic|avif|tiffoutput format (default: png)--size preview|full|50MP|autooutput megapixel cap--quality 1..100for lossy formats (default: 92)-o, --output <path>explicit output file--out-dir <dir>batch output directory
Server
--serverrun local HTTP API--host <addr>bind address (default: 127.0.0.1)--port <n>bind port (default: 8787)--corsenable CORS for allowed origins--allowed-origins <csv>add allowed browser origins--no-origin-check | --footgundisable browser origin checks--token <secret> | --token-autorequire Bearer token--public-healthkeep /health public on non-loopback binds--max-body-mb <n>request body limit (default: 32)
Meta & exit codes
--json | --ndjsonstructured output--quiet | --verboselogging level--version | --help | -hmeta--checkcapability report
| 0 | success |
|---|---|
| 1 | user error (bad input, refusing TTY) |
| 2 | parser error or no result |
| 3 | framework error (Vision unavailable) |
06 · Privacy
Run it with Wi-Fi off.
04
Images stay yours.
07 · Ecosystem
Part of the apfel family.
Install
Background, be gone.
$brew install Arthur-Ficial/tap/bgbgone