← Back to the editor

Guide

Make a smaller GIF

Why the file gets large

A GIF is not a modern video. Each frame keeps a palette of at most 256 colors, and the format repeats a lot of picture data over time. A wide frame, a high frame rate, and a long trim multiply together. That is why a ten-second screen recording at full desktop width can refuse to fit in a chat upload, even when the original MP4 was small.

YUIgif will not hide that cost. The controls that change size are on the editor: trim, width, frame rate, speed, colors, dithering, boomerang, and the size limit. Change the source of the size first. Use the limit as a backstop, not as the only setting.

The limits on the editor are 60 seconds, 1,800 frames, and 10 MiB. The size menu offers 2 MB, 4 MB, 8 MB, and 10 MB. Those labels use binary megabytes. 10 MB means 10 MiB, 10 × 1024 × 1024 bytes.

Cut time before you cut quality

Trim is the most honest saving. Set Start and End so only the action remains. A one-second loop is often clearer than a six-second loop, and it is a fraction of the file. For still images, shorten Hold for. A frame that sits for two seconds is paying for time the viewer already understood.

Speed can help after the trim. 1.5× or 2× keeps more of the action inside fewer seconds. Do this when the motion is still readable. 3× is a special effect more than a compression trick. Slowing the clip down does the opposite: it spends more time, and usually more frames, on the same gesture.

Boomerang plays forward and then back, so it doubles the duration. Leave it off while you are chasing a small file. You can turn it on after a short trim if the back-and-forth is the point. Reverse does not double the length. It only changes direction.

Width, frame rate, and palette

Width is the next large lever. 480 pixels is the default that the home page recommends for a first GIF. Drop further if the loop is a reaction face or a simple icon and the edges do not need detail. Raise it only after a small export looks soft. Width applies to the whole GIF, so you do not set it per file.

Frame rate at 12 is a balanced GIF. 8 fps is the smaller, slightly more stepped option, and it is often right for screen captures of a cursor or a still sequence. 20, 24, and 30 fps belong to short clips where smooth motion matters more than the upload limit. More frames mean a larger file and a longer conversion. They also push you toward the 1,800 frame cap sooner.

Colors are 32, 64, 128, or 256. Fewer colors make a simpler palette and often a smaller file, with more banding in gradients and skin tones. 128 is the editor's selected default and a fair middle. 32 is useful for flat illustration and hard on photographs. 256 spends the full GIF palette when the picture needs it.

Dithering is how the encoder simulates the colors it had to drop. Smooth dithering hides bands and can cost extra bytes. Pattern dithering is more visible and more regular. None leaves flat areas of the nearest palette color, which is the smallest and the harshest. For a flat logo, None can look clean. For a photo or a game capture, Smooth is usually kinder.

Use the size limit on purpose

Pick 2 MB when the destination is strict, 4 MB for a general share, and 8 MB or 10 MB when quality matters and the host allows it. If your chosen width and frame rate already fit, the limit does not need to damage the picture. If they do not fit, YUIgif may reduce resolution or the number of frames until the file fits. Watch the Result after that, because an automatic reduction can look softer than the width you typed.

A practical first recipe is 480 px, 12 fps, 128 colors, smooth dithering, and a 4 MB limit, with the trim already tight. Convert once. If the loop is too soft, raise width or colors and convert again. If it is too large, shorten the trim before you touch anything else.

Color effects such as grayscale or sepia do not replace these settings. They change the picture, and a simpler picture can encode smaller, but that is a look, not a plan. Cropping away empty edges does help, because those edges are still pixels. The edit guide shows how to apply a crop. The video guide and the image guide cover the import step that comes before any of this.

Fewer colors, side by side

Dropping the palette is one of the size levers. Here is the same still at 256 and 32 colors, encoded the way YUIgif does it. For flat artwork the lower setting is often invisible; for photos, compare before you commit. The palette and dithering guide has more examples.

Sunset test image at 256 colors.
256 colors · 22 KB
The same image at 32 colors with slight grain.
32 colors · 14 KB

Ready to try it on your own file? The GIF compressor opens the editor with the size controls ready.