Gifsicle logo

Gifsicle

Source and documentation
gifsicle-1.95.tar.gz (579636 bytes)
On Github

Prebuilt binaries
Debian Linux package (maintained by Gürkan Sengün)
FreeBSD port (maintained by Sylvio Amorim)
NetBSD package (maintained by Ben Wong)
Mac OS X HomeBrew port
MacPorts package (may be out of date)
DOS port (maintained by Robert Riebisch)
Windows ports (maintained by Jernej Simončič)

Read the gifsicle man page

Changes from other versions

Translations
French (by Nicolas Chevallier)

What is this?

Gifsicle is a command-line tool for creating, editing, and getting information about GIF images and animations. Making a GIF animation with gifsicle is easy:

gifsicle --delay=10 --loop *.gif > anim.gif
Extracting frames from animations is easy too:
gifsicle anim.gif '#0' > firstframe.gif
You can also edit animations by replacing, deleting, or inserting frames:
gifsicle -b anim.gif --replace '#0' new.gif

Some more gifsicle features:

  • Batch mode for changing GIFs in place.
  • Prints detailed information about GIFs, including comments.
  • Control over interlacing, comments, looping, transparency...
  • Creates well-behaved GIFs: removes redundant colors, only uses local color tables if it absolutely has to (local color tables waste space and can cause viewing artifacts), etc.
  • It can shrink colormaps and change images to use the Web-safe palette (or any colormap you choose).
  • Optimize your animations! This stores only the changed portion of each frame, and can radically shrink your GIFs. You can also use transparency to make them even smaller. Gifsicle’s optimizer is pretty powerful, and usually reduces animations to within a couple bytes of the best commercial optimizers.
  • Unoptimizing animations, which makes them easier to edit.
  • A dumb name.

Two other programs are included with gifsicle: gifview is a lightweight animated-GIF viewer which can show animations as slideshows or in real time, and gifdiff compares two GIFs for identical visual appearance.

Gifsicle is freely available. All you’ll need is an ANSI C compiler. I welcome changes, bug reports, complaints, etc.: mail me at ekohler@gmail.com!

Gifsicle questions

Let the person who isn’t actually buying anything but is rather downloading something for free, beware.

Q: How do you pronounce “gifsicle”?
A: “Yo’ mama.”

Q: What about patents?
A: The GIF image format had some patent problems in the past, but according to the Free Software Foundation, “The Software Freedom Law Center says that after 1 October 2006, there will be no significant patent claims interfering with employment of the GIF format.” [reference]

Other GIF tools

Whirlgif (an older version) merges single GIFs into animations, but cannot extract frames, edit animations, or use animations as input files. It either uses local color tables, or it changes input colors by only using colors from the first GIF frame. It also cannot handle complicated input transparency or more than 256 colors total. Gifsicle now uses its adaptive tree method for LZW encoding (thanks!) which makes it basically as fast as Whirlgif.

GIFMerge is based on an earlier program called txtmerge. Like Whirlgif, it cannot extract frames or edit animations. It also cannot optimize animations. Resulting animations always have local color tables. Doesn’t deal with input transparency.

Giftool does batch mode, comments, interlacing, and information, but doesn’t handle animations.

Of course, there are hundreds of programs available for Macs and Windows boxes!

There’s at least one GIF optimizer available via the Web. Submit a GIF URL to OptiView, and it spits out several impressively optimized versions for you to select from. As of mid-1998, gifsicle -O2 usually did about as well as GIF Wizard, OptiView’s predecessor.

Testimonials

This software is dedicated to the memory of Anne Dudfield, who named it, and who was an incredible friend and ridiculously awesome woman.

“I would even go so far as to say that it is stunning.”

Anne “Idiot” Dudfield

“[Gifsicle is] 10x faster than our previous converter.... The images are significantly smaller, too.”

Mike Hurwitz, Tumblr (another post)

“I just downloaded Gifsicle, and would like to make two small points:

  1. It is vastly better than GIFMerge and Whirlgif, in every way I could think of. Not least importantly, it reduced the GIF animations on my web site from 19MB total down to 11MB, which suddenly made my site much easier to navigate.
  2. Don’t be so hard on poor Anne, whoever she is; Gifsicle isn’t such a bad name (at least it’s memorable.)”
Jim Bednar

“YESYESYESYESYES I HAVE A DENTIST APPOINT MENT THAT DAY!!!

IT’S A VERY IMPORTANT DENTISST APOINTMENT, AS THEY ARE FILLING A CAVITY FROM WHICH THE LAST FILLING HAD FALLEN OUT, AND IT IS GETTING SENSITIVE!!!

CAN’T MISS THAT DENTIST APPPOINTMENT!!! CAN’T RESCHEDULE IT, AS THEY ARE VERY BUSY AT THE DENTIST PLACE!!!!!!!!!

YESSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSS”

Anne “Idiot” Dudfield

“God bless you and gifsicle! It is the answer to my prayers and yearnings. Linux go bragh.”

Patrick Killelea

Testimonials Européens

“...Gifsicle, manejador de gifs...”

Urko Lusa

Testimonialae Africanae

“Ja-nee swaer. Ek het nog steeds nie die ding gedownload nie, maar dit lyk vir my sonder twyfel nat-kak.”

Etienne Posthumus

Etienne Posthumus’s “rough” translation: “Well old boy. I haven’t downloaded it yet, but it looks hot-shit to me without a doubt.”
An independent translation: “Sure bro. I still haven’t downloaded the thing yet, but it looks to me without a doubt like wet shit.”
Eddie Kohler