When I try to make a gif with two frames both of which have a transparent background in GIMP, what happens is that the first frame looks OK, then the second frame appears on top of it, such that you can see both frames at the same time.

How can I make animated gif in which all of the frames have a transparent background but each time a frame appears, the previous frame disappears completely ?


When exporting/saving (depends on version) your work as GIF, you have several options for it. One way for that, what you probably want, could be done by choosing from "Frame disposal where unspecified" option "One frame per layer (replace)".

| improve this answer | |
  • I also had to make sure that I checked off "Use disposal entered above for all frames" -- I think because by default every layer had the "(combine)" on it. – Hannele Feb 28 '19 at 20:30

For the current version (2.8.0), in the name for each frame layer, include (replace). For example:

frame 1(250ms)(replace)

That will tell gimp to replace instead of stacking. Note that you can use the stacking for some pretty cool effects as well.

| improve this answer | |

Others answers involving gimp did not work for me. What fixed my gif is the command

gifsicle -U --disposal=previous -O2 source.gif > target.gif

| improve this answer | |
  • Both other answers are valid though. – xenoid Nov 11 '18 at 20:17
  • 1
    hence the "for me". I used gimp osx version, maybe it is related. – kraymer Nov 12 '18 at 5:36
  • Certainly not... You must have missed something. – xenoid Nov 12 '18 at 7:29
  • Nope, but my gimp version may be outdated. Anyway, just providing an alternative. – kraymer Nov 12 '18 at 9:57
  • I also had to make sure that I checked off "Use disposal entered above for all frames" – Hannele Feb 28 '19 at 20:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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