GIF and animation guides

Shrink an animated GIF while keeping every frame

·

An animated sticker is too large for a message. Try the smaller structural copy first. Compare the exact byte count before deciding whether to change the palette or scale.

GIF Compressor

Compare the source with a lossless copy

Open GIF Compressor and select Load example. The supplied 64 × 40 GIF has four frames and three total plays. Choose Keep colors and select Compress GIF.

The example goes from 7,700 to 2,296 bytes. It contains repeated color tables and comments that this mode can remove. Play the result and check the moving block, the transparent margins and the pacing.

Download the original four-frame practice GIFW3C copy of the GIF89a specification

Try a smaller palette and compare the preview

For the same example, select Reduce palette or size, choose 16 colors and leave Scale at 100%. Compress and compare the result with your lossless copy. The sample has only a few colors, so this preserves its main color blocks.

If your own GIF has gradients or detailed edges, fewer colors can change them. To reduce both dimensions proportionally, lower Scale and check the planned pixel size before running the job.

Download the original four-frame practice GIFImageMagick animation tools, frame coalescing and disposal

Check the animation length and save the result

The example stores delays of 30, 110, 240 and 80 ms. Its four frames still play for 460 ms per pass. Keep every frame to preserve all four stored delays and the three total plays. Choose Keep every second frame to keep frames 1 and 3 for 140 and 320 ms respectively. The movement has fewer steps and the total remains 460 ms per play.

If the tool offers Download original GIF, the source is already as small as the current candidate or smaller. You can keep those original bytes or change the palette or scale and compare again.

Download the original four-frame practice GIFW3C copy of the GIF89a specification

Common questions

Does Keep colors remove comments?

Yes. This mode removes GIF comment blocks, repeated local color tables and any bytes after the GIF end marker. The displayed frames, stored delays and loop are kept.

Why can the palette option change transparent edges?

Scaling interpolates boundary pixels. GIF stores each pixel as opaque or transparent, so the encoder converts a resampled edge to those two alpha states.

Sources

Put it into practice.

Related guides