Change how many times a GIF loops

Drop a GIF here

or click to choose — any size, nothing is uploaded

Drop in a GIF and see what its loop setting says right now — loop forever, play a few times, or no setting at all, which makes it stop after one play. Then choose how it should play and download it. Only the small loop setting inside the file is rewritten: every frame, colour and delay stays exactly as it was. Nothing is uploaded, and there is no watermark.

How to change a GIF's loop

  1. Drop a GIF into the box above, or click it to choose one. The page reads the file and tells you how it plays now.
  2. Choose Loop forever, Play once, Play a set number of times (then type the number), or Stop within 5 seconds.
  3. Press Save GIF. The result plays below; Play from the start restarts it so you can count the plays.
  4. Download it. The file name says what you chose, for example party-loop.gif or banner-3-plays.gif.

The number in a GIF counts repeats, not plays

Whether a GIF loops is not up to the browser or the app showing it; it is a small setting stored near the start of the file. Its number is easy to misread. It does not say how many times the GIF plays: it says how many times to repeat after the first play, and 0 is a special value that means forever. So a loop count of 1 gives two plays, and the only way to get exactly one play is to have no loop setting at all.

We checked this rather than take it from the specification. A four-frame test GIF, 0.8 seconds per play, was saved with each setting and watched frame by frame in Chrome 156 and Microsoft Edge for six seconds:

Stored in the filePlays in Chrome and EdgeWhat this page calls it
No loop setting1, then stops on the last framePlay once
Loop count 122 plays
Loop count 233 plays
Loop count 344 plays
Loop count 455 plays
Loop count 0Still playing when we stopped watchingLoop forever

That is why this page asks how many times you want the GIF to play and writes the matching number itself. In the test, every choice played exactly as many times as chosen in both browsers.

Odd files we also tested

GIFs made by older or unusual tools sometimes store the setting in a non-standard way. The page recognises these and says so when you drop the file in; saving leaves a single, standard loop setting before the first frame.

  • Two loop settings in one file (one saying three plays, a later one saying forever): Chrome and Edge followed the last one and looped forever.
  • Loop setting placed after the first frame instead of before it: both browsers still read it.
  • The old ANIMEXTS1.0 label instead of NETSCAPE2.0: both browsers treated it the same way.

Why some GIFs stop after one play

Because nothing told them to loop. The app or code that made the GIF decides whether to write a loop setting, and their defaults differ. Two we checked:

Made withDefault when you don't choose
Python's Pillow library 12.3, save_all=True without loopNo loop setting: plays once
FFmpeg 7.1, plain ffmpeg -i clip.mp4 out.gifLoop count 0: loops forever
FFmpeg 7.1 with -loop -1No loop setting: plays once

Design apps usually ask: Photoshop's Save for Web has a Looping Options menu, and our own Images to GIF has a Repeat choice. If a GIF used to loop and stopped after you edited it, the editor dropped the setting; this page puts it back. If it stopped moving entirely, see why a GIF is not moving — a single-frame file has nothing to loop, and the page tells you so.

Stopping a GIF within five seconds

On websites, WCAG success criterion 2.2.2 asks that anything that moves on its own for more than five seconds can be paused or stopped. One way the W3C lists to meet it, technique G152, is a GIF whose plays add up to five seconds or less. Stop within 5 seconds does that arithmetic from the GIF's own frame delays: a 1.2 second animation gets 4 plays (4.8 seconds), a 2.5 second one gets 2, and a 3 second one gets 1. The page shows the total before you save. If a single play is already longer than five seconds, no loop setting can help, and the page says so; the options then are a shorter animation or a pause button on the page.

What saving changes, and what it does not

The loop setting is a block of 19 bytes. Saving removes any loop blocks the file has, writes one new block in the standard place (or none, for Play once), and copies every other byte unchanged. Frames are not decoded or re-encoded, so no colour, transparency or delay can change, and the file size moves by at most 19 bytes per block.

We tested that on thirteen GIFs — our five usual test animations (a transparent emoji, a screen recording, an interface animation, a colour pan and a noisy video clip) plus eight files built to be awkward: no loop setting, a loop count of 3, a comment block, the old label, a late setting, two settings, and a single-frame GIF87a file. Each was saved five ways (1, 2, 3 and 5 plays, and forever). In all 65 results, read back independently, every frame's pixels and every delay matched the original, the stored loop value was the expected one, and apart from the loop block not one byte differed. A GIF that is cut off at the end is kept as it is, missing part included.

Things this page does not do

  • Back-and-forth (boomerang) loops. That needs the frames played in reverse and added to the end, which is a different edit.
  • Speed. Changing how fast it plays means changing every frame delay. To shorten or slow a clip, convert it with GIF to MP4, change it there, and turn it back with Video to GIF.
  • Choosing the frame it stops on. A GIF that stops always rests on its last frame. If that frame looks wrong when it stops, the fix is in the animation itself.
  • Forcing an app to obey. Some apps replay GIFs their own way or convert them to video. Test the file in a browser: if it loops correctly there, the file is right.

To make the GIF smaller as well, use Compress GIF, Resize GIF or Crop GIF; all three keep the loop setting you give it here. Your GIF is never uploaded — see where your files go.

Frequently asked questions

How do I make a GIF loop forever?

Drop the GIF into the box above, leave the choice on Loop forever and press Save. The downloaded GIF repeats endlessly in browsers, chat apps and slides that play GIFs at all. Nothing else in the file changes, so it looks and weighs the same.

Why does my GIF stop after playing once?

Because the file has no loop setting. Without one, a GIF plays through once and stays on its last frame. That is the default in some tools: a GIF saved with Python's Pillow library without a loop value, for example, plays once. Drop it here and the page will say 'No loop setting'; choose Loop forever to fix it.

How do I make a GIF play only once?

Choose Play once. The page removes the loop setting from the file, which is the one way to get a single play: writing a loop count of 0 means forever, and a count of 1 means repeat once, so two plays. The GIF stops on its last frame.

Is the loop count the number of plays?

Not in the file. The number stored in a GIF is how many times to repeat after the first play. We tested it in Chrome 156 and Edge: a stored count of 1 played twice, 2 played three times, and no setting at all played once. This page asks how many times you want the GIF to play and writes the matching number, so 3 plays means 3 plays.

Can I make a GIF stop within 5 seconds for accessibility?

Yes. Choose Stop within 5 seconds and the page works out how many full plays fit in five seconds from the GIF's own frame delays. WCAG 2.2.2 asks that motion lasting longer than five seconds can be paused, and the W3C lists a GIF whose plays add up to five seconds or less as one way to meet it (technique G152). If one play already lasts longer than five seconds, the page says so, because no loop setting can fix that.

Does changing the loop lower the quality or the file size?

No. The loop setting is a 19-byte block near the start of the file. The page replaces only that block and copies every other byte as it was. In our tests on thirteen GIFs, every frame and every delay in the result matched the original exactly, and the file size changed by at most 19 bytes.

Why does my GIF still play once in PowerPoint or another app?

Some apps decide for themselves. PowerPoint only plays GIFs in Slide Show, and PowerPoint for the web does not animate them at all; some chat apps and email clients turn GIFs into their own looping videos. We checked the result in Chrome and Edge, where it played exactly the number of times chosen. If one app ignores the setting, test the file in a browser first: if it loops there, the file is right and the app is overriding it.

Is my GIF uploaded?

No. The file is read on your device, the loop block is rewritten in memory and the result is offered as a download. There is no size limit from us, no account and no watermark.