One Tip a Week: ffmpeg + AI = Easy GIFs

This week’s tip is a combo: ffmpeg, but with a little help from AI tools like ChatGPT or Claude.

I’d never touched ffmpeg before, but I asked ChatGPT: “I have an mp4 video. How can I convert part of it to an animated gif?”. It instantly gave me a working command:

ffmpeg -ss 00:00:10 -t 5 -i input.mp4 \
  -vf "fps=15,scale=480:-1:flags=lanczos" output.gif

That wasn’t exactly what I wanted, but after a couple more prompts, I came up with this:

ffmpeg -ss 00:00:26 -t 12 -i input.mp4 \
  -vf "fps=30,split[s0][s1];[s0]palettegen=max_colors=256[p];[s1][p]paletteuse=dither=bayer:bayer_scale=5:diff_mode=rectangle" output.gif

And just like that I had a 12 seconds clean, high‑quality animated GIF in a couple minutes. No fancy video editor, just a single open‑source tool + AI guidance. Sometimes you don’t need to know the tool, just how to ask the right question.

My 12 second clip

For the curious, here’s the original video. Next time you need something done to a video, see what ChatGPT/Claude offers as a command suggestion via ffmpeg, and let me know on socials!

That’s it! Short and sweet. Until the next one!