When you save a GIF in GIMP, you're given the option to use cumulative layers (combine) or one frame per layer (replace).

Choosing cumulative layers causes the GIF's layers to only contain the pixels that changed since the last frame.

Choosing one frame per layer causes each of the GIF's layers to save all of its pixels, not relying on any of the pixels from the last frame.

If a GIF has been previously saved with cumulative layers, and I delete the first few frames, it messes up the rest of the GIF because the later frames were relying on the (now deleted) color information from the first frames.

Here's an example:


enter image description here

After deleting the first two frames:

enter image description here

How can I save the modified GIF so that it looks correct?

3 Answers 3


This is real easy in gimp. You unoptimize the gif to reveal all pixel data in layers (filters/animation/unoptimize). Delete the layers, 2 first in your case, then optimize it again (filters/animation/optimize for gif) Export as gif, tick the animation box.

  • Perfect! I wasn't aware of the unoptimize feature. Commented Jan 11, 2016 at 4:53

The whole idea behind Cumulative (Combine) is to cut down the size of the file by eliminating the parts that don't change and keeping the bits that do. If you want to go the Replace route (and I can't imagine why, but okay), make a copy of the first layer and merge the copy with the next layer up. Then make a copy of the new layer and merge that with the next layer up. And so on, ad naus. Save as animation.

Yes, it's a rather clunky solution.

  • That would be very tedious if the GIF has 100 frames. Do you know if there's any way to automate it? Photoshop has a way of doing it automatically. Commented Jun 21, 2015 at 19:25
  • Also, I renamed the title of the post. I don't actually care if the new GIF uses Replace or Combine, but it has to look correct. Commented Jun 21, 2015 at 19:27
  • Tedious? You betcha. I honestly don't know about automating the process, I don't play with GIFs much. Somebody clever with Python could probably come up with a script.
    – pbr
    Commented Jun 21, 2015 at 23:32

To make it less clunky I created a merge down shortcut in gimp.

The duplicate layer shortcut is: ctrl+shift D

i created a merge down shortcut in preferences like so so i can leave the figers on the ctrl+shift button.

ctrl+shift M

Then start at background layer (bottom one) and do:

ctrl+shift D > arrow up > ctrl+shift M

and so on

when finished export as gif there you can choose the "framedisposal where unspecified" to safe it as "one frame per layer (replace)"

  • 1
    Welcome! Can you please add one or more screenshots to show the way? Thanks!
    – Mensch
    Commented May 5, 2016 at 16:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.