What it does
Takes your video and repeats it the number of times you specify (2 to 20), producing a single output file. The looped result plays the original clip back-to-back without any pauses or transitions.
Uses FFmpeg’s stream_loop flag with stream copy, no re-encoding, so the output retains the original quality and processes very fast.
When you’d loop a video
- Short reaction GIFs / memes: a 2-second clip looped 5x becomes a 10-second video that’s perfect for social media where short loops play forever.
- Background loops: a 10-second nature scene looped 6x becomes a 60-second background for a presentation.
- Music videos for short audio loops: pair with the same-length audio loop.
- Stress testing players: long files (looped from short ones) test buffer behavior.
- Replacing animated GIFs with smaller MP4s: an MP4 loop is often 10x smaller than a GIF of the same length and quality.
How looping works under the hood
FFmpeg’s -stream_loop N reads the input N times before output. Combined with -c copy, it doesn’t re-decode/re-encode, it just rewrites the container with duplicated stream data. This is why the operation is fast and lossless.
The downside: codec keyframes have to align across loops. For most modern formats (H.264, H.265, VP9), this works seamlessly. For some older formats or with certain encoder settings, you may see a brief glitch at loop boundaries. If that happens, the workaround is full re-encode (which we don’t currently expose).
Output duration math
Output duration = original duration × loop count. So:
- 5-second clip looped 4× = 20-second output
- 30-second clip looped 10× = 5-minute output
- Maximum cap: 20 loops, capping abuse on long inputs
Output file size scales linearly with loop count too, a 10MB clip looped 5× produces a ~50MB file.
Frequently asked questions
Why does the loop have a tiny pause at each repeat? Some video players show a brief frame of black between loop iterations because the I-frame at the start of each loop iteration takes a moment to decode. Hardware accelerated playback (modern phones, recent computers) usually handles this seamlessly.
Can I add a fade between loops? Not currently, that would require re-encoding. A future tool or the existing video editor could do this.
Does the audio loop too? Yes. The entire stream (video + audio) loops together, so audio repeats in lockstep with video.
What’s the difference between this and video merger? Loop repeats the same video N times. Merger combines N different videos into one. Use loop for “play this thing 5 times”; use merger for “play A then B then C.”