WebP to GIF: How to Convert Animated WebP on Mac (Tested)
WebP to GIF: The Short Answer
To convert WebP to GIF on a Mac and keep the animation, use a tool that can actually decode animated WebP. The quickest is FFmpeg 9.0 or newer:
ffmpeg -i input.webp -filter_complex "[0:v]split[a][b];[a]palettegen[p];[b][p]paletteuse" output.gif
ImageMagick 7 (magick input.webp output.gif) works too, and so does gifski if you feed it the frames. Two things to expect: the GIF will usually be 2-5 times larger than the WebP, and colours, semi-transparent pixels and very short frame delays get simplified, because GIF is a much older format. For a still (non-animated) WebP, the built-in sips command is enough.
Everything below was tested on macOS 27.2 with FFmpeg 9.1, ImageMagick 7.1.2-16, libwebp 1.6.0 and gifski 1.34.0, using animated WebP files we made ourselves. We'll cover how to tell whether your WebP is animated, every conversion method that worked (and the ones that silently didn't), what we measured, and how to shrink the GIF afterwards.
Static vs Animated WebP: Check Which One You Have
WebP comes in two flavours that need different handling:
- Static WebP is a single image, like a JPG or PNG. Converting it to GIF is simple, but there's rarely a reason to: a still GIF is limited to 256 colours, so WebP to PNG or WebP to JPG is almost always the better choice.
- Animated WebP stores a sequence of frames inside
ANIMandANMFchunks, each frame with its own duration, position and blend settings. This is the case where GIF makes sense, and where many tools fail.
The file command doesn't help much: it labelled our animated file just "RIFF (little-endian) data, Web/P image". Better options:
webpmux -info input.webp # from libwebp: "Features present: animation" + frame table
ffprobe -v error -show_entries stream=codec_name -of csv=p=0 input.webp
# FFmpeg 9.x prints webp_anim for animated files, webp for still ones
webpmux -info also lists every frame's duration, size and offset, which is handy when you want to check the GIF's timing against the original later.
Why Convert WebP to GIF at All?
WebP is the better format: smaller files, full colour and real alpha transparency. (That's why we wrote a whole guide on going the other way, GIF to WebP.) Converting to GIF is about compatibility, not quality:
- Email. According to caniemail.com's test data, Gmail converts WebP images to JPG and doesn't support WebP animation, and Outlook's Windows Mail app doesn't animate WebP either. Animated GIFs are the long-standing safe choice in email.
- Upload forms and older software that accept
.gif,.jpgand.pngbut reject.webp, or accept it and keep only the first frame. - GIF-centric workflows: reaction-GIF libraries, slide decks, documentation tools and chat setups where GIF is the format everyone already knows will play.
- Files saved from the web. Many sites now serve animations as WebP, so the "GIF" you right-click and save often arrives as a
.webpthat won't play where you need it.
All current major browsers play animated WebP, so for your own website you usually want to keep WebP (or switch to video) rather than convert.
How to Convert WebP to GIF with FFmpeg
FFmpeg is the most flexible option, but the version matters. For years FFmpeg could only decode still WebP; the bug ticket requesting animated WebP decoding (#4907) was opened in 2015. FFmpeg's changelog finally lists an "Animated WebP decoder" and "Animated WebP demuxer" under version 9.0, released in August 2026. If you're on 8.x or older, FFmpeg can't decode the animation (one independent test of 8.1.2 got zero frames), so update first or use ImageMagick.
Check your version:
ffmpeg -version | head -1
The one-liner (fast, but ugly)
ffmpeg -i input.webp output.gif
This works on FFmpeg 9.x and keeps every frame, but FFmpeg's default GIF encoding uses a fixed, generic palette and dithers heavily. On our 480×270 photographic test clip it produced a visible crosshatch pattern over the sky. Fine for a quick test, not for anything you'll share.
The palette method (recommended)
ffmpeg -i input.webp \
-filter_complex "[0:v]split[a][b];[a]palettegen[p];[b][p]paletteuse" \
output.gif
palettegen builds the best 256 colours for this specific clip, and paletteuse maps every frame to them. The result looked much closer to the WebP, at the cost of a much bigger file (see the measurements below). Variations worth knowing:
# Smaller file: favour colours in moving areas, ordered dithering, only re-encode changed regions
ffmpeg -i input.webp -filter_complex \
"[0:v]split[a][b];[a]palettegen=stats_mode=diff[p];[b][p]paletteuse=dither=bayer:bayer_scale=5:diff_mode=rectangle" \
output.gif
# Much smaller: 10 fps, 320 px wide, 128 colours
ffmpeg -i input.webp -filter_complex \
"fps=10,scale=320:-1:flags=lanczos,split[a][b];[a]palettegen=max_colors=128:stats_mode=diff[p];[b][p]paletteuse=dither=bayer:bayer_scale=4:diff_mode=rectangle" \
output.gif
These are the same palette techniques we use for WebM to GIF and other video to GIF conversions; once FFmpeg can decode the animated WebP, it treats it like any other video stream.
Loop count with FFmpeg
FFmpeg's GIF muxer loops forever by default. Our test WebP was set to play 3 times, and FFmpeg's GIF still looped infinitely. If the loop count matters, set it yourself with -loop (0 = forever, -1 = play once):
ffmpeg -i input.webp -loop 3 -filter_complex "[0:v]split[a][b];[a]palettegen[p];[b][p]paletteuse" output.gif
Decoders don't all count GIF loops the same way (some treat the number as repeats after the first play), so check the result in the app you're targeting.
Batch convert a folder
for f in *.webp; do
ffmpeg -hide_banner -loglevel error -n -i "$f" \
-filter_complex "[0:v]split[a][b];[a]palettegen[p];[b][p]paletteuse" "${f%.*}.gif"
done
-n skips files that already have a GIF. This handled a mixed folder of animated and still WebPs in our test.
Convert Animated WebP to GIF with ImageMagick
ImageMagick reads animated WebP through libwebp and writes GIF in one step:
magick input.webp output.gif
Use magick, not convert: in ImageMagick 7 the old convert command is deprecated (many top-ranking guides still show it). In our tests ImageMagick:
- Kept every frame, writing each one as a sub-rectangle at its original offset, just like the WebP.
- Carried over the loop count. Our "play 3 times" WebP became a GIF with a loop value of 2 (GIF's loop field is commonly read as repeats after the first play), where FFmpeg defaulted to looping forever.
- Kept irregular frame timing. A test file with frames of 500, 100, 1,000 and 40 ms came out as 50, 10, 100 and 4 hundredths of a second. FFmpeg got the first three right but stretched the final 40 ms frame to 100 ms.
- Rounded uniform timing slightly. For a steady 67 ms per frame, ImageMagick wrote 7/100 s for every frame (the clip runs about 5% slower), while FFmpeg and gifski alternated 6 and 7 to keep the average.
For files with uneven frame durations (common in stickers and reaction animations), ImageMagick is the safer choice.
gifski: Best-Looking GIFs, With One Catch
gifski is a high-quality GIF encoder that builds a palette per frame and uses temporal dithering. It can't read WebP directly, so extract the frames with FFmpeg 9 first:
mkdir frames
ffmpeg -i input.webp frames/f%04d.png
gifski --fps 15 --quality 80 -o output.gif frames/f*.png
Set --fps to match the source (1000 ÷ frame duration in ms; a 67 ms frame is 15 fps). That's the catch: when you feed gifski PNG files, every frame gets the same duration, so variable timing from the WebP is lost. Use it for steady clips, and ImageMagick for animations with deliberate pauses.
gifski handled transparency better than the others in our test, approximating semi-transparent areas with a scattering of transparent pixels rather than a hard cut.
What About Preview, sips and libwebp's Own Tools?
We tried the tools that ship with macOS and the official libwebp tools. None of them produced an animated GIF:
| Tool | What happened with our animated WebP |
|---|---|
| Preview (macOS 27.2) | Opened the file and showed every frame as a thumbnail in the sidebar, like pages of a PDF. Didn't play the animation. |
| sips | sips -s format gif input.webp --out output.gif wrote a GIF with only the first frame (65 KB). No warning. |
| dwebp | Refused with "Status: 4(UNSUPPORTED_FEATURE)". dwebp decodes still WebP only. |
| webpmux -get frame N | Extracts one frame's raw data. In our clip, frame 5 came out as a 480×120 strip, because animated WebP frames only store the changed region. Not a usable full frame. |
| gif2webp | Converts in the opposite direction only. |
macOS itself can read animated WebP: Apple's ImageIO framework reported all 45 frames and their 0.067 s delays when we queried it, and it can write GIF. The built-in apps just don't expose an animated WebP to GIF export. libwebp's anim_dump example tool can dump full frames, but the Homebrew webp package we tested (1.6.0) didn't include it.
For a still WebP, sips is the easiest built-in route:
sips -s format gif input.webp --out output.gif
Our 6.9 KB still WebP became a 16.8 KB GIF. Again, PNG or JPG is usually the better target for a still image.
WebP to GIF File Size: What We Measured
Here's the honest part most converters skip. We made a 3-second animated WebP from a 4K macOS wallpaper video: 480×270, 15 fps, 45 frames, lossy quality 75, 435 KB. Then we converted it every way that worked:
| Method | GIF size | vs WebP | Notes |
|---|---|---|---|
ffmpeg -i in.webp out.gif | 726 KB | 1.7× | Heavy crosshatch dithering |
| FFmpeg palettegen + paletteuse | 1,989 KB | 4.6× | Close to the original look |
FFmpeg palette, stats_mode=diff + Bayer | 1,534 KB | 3.5× | Good balance |
ImageMagick magick | 1,614 KB | 3.7× | Keeps timing and loop count |
| gifski, quality 90 (default) | 1,458 KB | 3.4× | Smoothest gradients |
| gifski, quality 70 | 690 KB | 1.6× | Slight noise, much smaller |
Even a simple synthetic test pattern grew from 244 KB to 693 KB (2.8×) with the palette method. The reasons are structural:
- 256 colours per frame. WebP stores full 24-bit colour. GIF must pick at most 256 colours per frame and dither the rest, and dithering noise is hard to compress.
- Old compression. GIF uses LZW, a lossless scheme from the 1980s. Lossy WebP uses VP8 prediction and transforms, which are far more efficient for photographic content.
- 1-bit transparency. One palette entry is "transparent"; everything else is fully opaque.
- Centisecond timing. GIF delays are stored in hundredths of a second, WebP's in milliseconds, so an 83 ms frame becomes 8 or 9 hundredths. Very short delays are a bigger problem: browsers have historically bumped GIF delays of 0 or 1 hundredth up to about 100 ms, so ultra-fast WebP animations can play slower as GIFs.
Transparency in practice
We also converted a transparent WebP with a 90% opaque circle and a 50% opaque blue band:
| Method | Result |
|---|---|
ffmpeg -i in.webp out.gif | Transparency lost, black background |
| FFmpeg palettegen + paletteuse | Transparent background kept; 50% band became fully opaque |
| ImageMagick | Same as the palette method |
| gifski | Transparent background kept; band dithered with scattered transparent pixels |
If your WebP has soft shadows or feathered edges, expect them to look jagged as a GIF, whatever tool you use. For animations that need real alpha in a format apps understand, APNG keeps 8-bit transparency, though it's less widely supported than GIF outside browsers.
How to Shrink the GIF After Converting
Because the GIF starts out 2-5× larger than the WebP, shrinking it is usually part of the job. The levers, roughly in order of impact:
- Width. File size scales with pixel count. Halving the width cuts the pixels to a quarter.
- Frame rate. 10-15 fps is plenty for most reaction GIFs and UI demos.
- Quality and colours. Lower gifski quality, or fewer palette colours in FFmpeg.
- Length. Trim frames you don't need.
Re-encoding our 1,989 KB palette-method GIF with gifski:
| Settings | Size |
|---|---|
| gifski quality 90 | 1,399 KB |
| gifski quality 70 | 731 KB |
| gifski quality 50 | 300 KB |
| gifski quality 70, 320 px wide | 275 KB |
| FFmpeg straight from WebP: 320 px, 10 fps, 128 colours | 455 KB |
At 320 px wide and quality 70, the GIF ended up smaller than the original WebP, and at chat-message size the difference is hard to see. For more techniques, see how to reduce GIF file size and compressing GIFs without losing quality. If you have a hard limit, like Discord's 256 KB emoji cap, our Discord GIF guide walks through hitting it.
Where Compresto Fits
To be clear about what Compresto does and doesn't do here: Compresto doesn't convert WebP to GIF. It opens WebP files as images, and its image output formats are JPG, PNG, WebP and AVIF. Its WebP encoder works from the first frame, so it isn't the tool for keeping a WebP animated either. Do the conversion with FFmpeg 9, ImageMagick or gifski as shown above.
Where Compresto helps is the step after:
- Compressing the GIF. Drop the converted GIF onto Compresto and it re-encodes it with gifski, the same encoder we used in the shrinking tests above, at a quality level you choose (Highest through Acceptable), with optional resizing. If a pass doesn't make the file smaller, it retries at the next lower quality. It works on batches, entirely on your Mac, with nothing uploaded. More on that in our GIF compressor guide.
- Making GIFs from video. If you have the original clip rather than a WebP, Compresto's video to GIF conversion also uses gifski, which skips the WebP step entirely.
- Going the other way. If you're the one publishing the animation, keeping it as WebP is usually the smaller choice; see how to compress WebP.
Frequently Asked Questions
Can I convert an animated WebP to GIF without losing the animation?
Yes, if the tool decodes animated WebP. FFmpeg 9.0 or newer, ImageMagick 7 and gifski (fed frames from FFmpeg) all kept every frame in our tests. Tools that only read the first frame, such as macOS sips, give you a still GIF. Expect some colour loss either way, because GIF is limited to 256 colours per frame.
Why is my GIF so much bigger than the WebP?
GIF uses 1987-era LZW compression and a 256-colour palette, while WebP uses modern VP8 or lossless compression with full colour. In our test a 435 KB animated WebP became a 1.4-2 MB GIF with good-quality settings. Lower the gifski quality, reduce the width or frame rate, or cut colours to bring it back down.
Can FFmpeg convert animated WebP to GIF?
Only recent versions. FFmpeg added an animated WebP decoder and demuxer in version 9.0 (August 2026); the request for it had been open since 2015. Older builds can't decode the animation. Run ffmpeg -version, and if it reports 9.0 or later, ffmpeg -i input.webp output.gif works, preferably with the palettegen and paletteuse filters for better colour.
Can Preview convert WebP to GIF on a Mac?
Not as an animation. On macOS 27.2, Preview opened our animated WebP and listed each frame as a thumbnail in the sidebar, but it didn't play it. The sips command, which uses the same macOS image system, wrote only the first frame to the GIF. For a still WebP, sips -s format gif input.webp --out output.gif works fine.
Does transparency survive a WebP to GIF conversion?
Partly. WebP has a full 8-bit alpha channel; GIF has one transparent palette entry, so each pixel is either fully transparent or fully opaque. In our test, FFmpeg's palette filters and ImageMagick turned a 50% transparent area fully opaque, and gifski dithered it with a scattering of transparent pixels. Soft shadows and anti-aliased edges are where you'll notice it.
How do I make the converted GIF smaller?
Reduce what the GIF has to store: scale it down (320 px wide is often enough for chat), drop the frame rate to 10-15 fps, trim frames and lower the quality. Re-encoding our 2 MB GIF with gifski at quality 70 and 320 px wide gave 275 KB, smaller than the original WebP. Compresto does this kind of gifski re-encode on any GIF you drop in.
The Short Version
Check whether your WebP is animated first (webpmux -info or ffprobe). For a still WebP, sips converts it in one line, though PNG or JPG is usually a better target. For an animated WebP, use FFmpeg 9.0 or newer with palettegen/paletteuse, ImageMagick's magick input.webp output.gif when frame timing and loop count matter, or gifski for the best-looking steady clips. Preview, sips, dwebp and webpmux won't give you an animated GIF. Expect the GIF to be 2-5× bigger than the WebP and to lose semi-transparency, then shrink it by cutting width, frame rate and quality.