GIF video thumbnail with FFmpeg I'm trying to generate a GIF thumbnail out of a video, similar to what youtube thumbnail works when we hover the mouse on a thumbnail as a video preview.

Is there any ways to do it with FFmpeg? Say I want to generate a 2-3 second GIF out of a video. How can I do that? Based on what I see from youtube, apparently it takes one frame out of multiple consecutive frames, not all of them.

I'm not really concerned if that GIF is a good representative of the video as that is more semantic problem to investigate.
There is thumbnail filter just for that, and palettegen/paletteuse to create high quality gif.

Example command: "scale=vga,thumbnail=100,split[a][b],[b]palettegen=reserve_transparent=0:stats_mode=single[b];[a][b]paletteuse=new=1,settb=1/25,setpts=N"

Thumbnail filter selects one frame from set of 100 frames. To get gif of 3 secs, you will need to adjust this number to smaller or bigger value depending on source file number of frames.