When GIF is the right output
GIF exists for one modern reason: short looping animation without an audio track, embeddable in older email clients and messaging platforms. Static GIFs are almost never the right choice — PNG (lossless) or JPG (compressed) is always better. Animated GIFs are limited to 256 colours and grow quickly; MP4 or WebP is typically better for anything over 2-3 seconds.