Cookies for analytics and advertising
We use cookies for analytics and advertising, both sent to Google. Refusing changes nothing you can see.Read the privacy page
GIF
Limited to 256 colours, but the only image format everything animates. Large files for video-like content.
GIF is a binary format, meaningful only to a program that knows it. It stores a grid of pixels, so enlarging it past its own resolution softens it. It is used for the web.
The extension is .gif, and the full name is Graphics Interchange Format. Both matter less than what the file can hold, which is what the rest of this page is about.
CompuServe published it in 1987. The specification is GIF89a.
A format that has been readable for that long is a format worth trusting with something you want back in ten years.
Anyone can implement it without asking permission or paying a licence, which is why it turns up in so many programs and why files written twenty years ago still open.
It still opens everywhere and is still written by older tools, but nothing new is being built around it. Convert what you mean to keep, and do not choose it for something starting today.
GIF stores its content exactly. Saving it again changes nothing, so it can be opened, edited and re-saved as often as you like without accumulating damage — which is what makes it a working format rather than a delivery one.
GIF carries an alpha channel, so a logo keeps its soft edges over whatever sits behind it instead of arriving in a white box.
GIF can store an animation rather than a single still. That is worth knowing before converting one: a target that holds one frame keeps the first and drops the rest, usually without saying so.
Up to 8 bits per channel. It can work in an indexed palette.
Eight bits per channel is what a screen shows and what nearly every delivery format carries.
The palette is the constraint everything else follows from. A photograph converted into it has to have its colours chosen and approximated, which is why gradients come out in bands or speckles, and why flat-coloured artwork survives it perfectly.
GIF cannot describe an image larger than 65,535 pixels on a side. That is far beyond an ordinary photograph and well within reach of a stitched panorama or a high-resolution scan, which is exactly when people meet it.
GIMP, Adobe Photoshop and ImageMagick read it, and so do most programs of the same kind.
If a file will not open, the format is rarely the problem — it is more often that the program predates it. Converting to something older is the reliable way past that, and it is what the rest of this site is for.
Every current browser reads it.
That makes it a safe thing to put on a page or attach to a message without wondering what the other end has installed.
GIF is meant to be handed over rather than worked in. Editing one is possible and rarely pleasant; the sane approach is to change the source and export again.
The recurring complaints: smooth gradients can come out in visible steps.
None of these is a reason to avoid the format. They are the things worth knowing before you are surprised by one, which is a different claim and a more useful one.
| Extension | .gif |
|---|---|
| Media type | image/gif |
| Published by | CompuServe |
| First published | 1987 |
| Specification | GIF89a |
The claims on this page are checkable, and these are the documents that settle them.