Convert MP4 to GIF in your browser, with trim
Turn a short MP4 into an animated GIF for places that take an image, not a video player: an email, a README, a backup image for a banner. Cut the part you need, pick 4 to 30 frames per second and a frame size. ffmpeg runs on this page, so the clip never leaves your computer.
- Trim to a start and end time
- 4, 5, 8, 15, 24 or 30 fps
- One palette for the whole clip
- Loop or play once
- No upload and no account
How it works
- Step 1
Drop an MP4 up to 500 MB on the box, or click to choose one. It opens in this tab; nothing is uploaded.
- Step 2
Set the start and end if you need only part of it, then the frame rate, size and loop. Press Convert to GIF.
- Step 3
The first run loads the converter (about 30 MB, kept by your browser for next time). Check the result and its size, then download it.
What each setting does to the GIF
- Start and end
- Seconds from the beginning of the MP4, such as 1 and 6. Leave either empty to keep the start or the end. The cut is frame-accurate, and it is the strongest size setting you have: every second you drop is a second of frames you don't store.
- Frame rate
- The
fpsfilter picks frames evenly across the clip, so the GIF keeps the clip's length; fewer frames make it look steppier, not faster. 4 fps is the fastest rate that meets Google Ads' "slower than 5 fps" rule for animated image ads, and both 4 and 5 fps divide evenly into the hundredths of a second GIF timing uses. - Frame size
- 100, 75 or 50 percent of the width and height, rounded to even numbers. Half size is a quarter of the pixels, and on small screens it rarely looks worse.
- Palette
- ffmpeg builds one 256-colour palette from the parts of the clip that move, then maps every frame to it with error-diffusion dithering. One shared palette keeps logos and text from flickering between frames.
- Playback and sound
- Loop writes the standard loop marker, so browsers and chat apps repeat it; Play once stops on the last frame. GIF has no audio, so any soundtrack is left out.
Measured: one 6 second MP4, four GIFs
On December 5, 2026 we ran this page in Chrome on a laptop with one of our own recordings: a 1080×1080 product card, 6 s at 30 fps, 224 KB as H.264. The first three rows cut it to 1–6 s.
| Settings | GIF size | Frames | File size |
|---|---|---|---|
| 1–6 s, 4 fps, 50% | 540×540 | 20 | 230 KB |
| 1–6 s, 5 fps, 50% | 540×540 | 25 | 277 KB |
| 1–6 s, 15 fps, 50% | 540×540 | 75 | 592 KB |
| Whole clip, 15 fps, 100% | 1080×1080 | 90 | 1.9 MB |

Every row is larger than the 224 KB MP4 it came from. That is normal: H.264 stores only what changes between frames, while GIF stores each frame as an indexed image. Halving the frame size and cutting to 4 fps took the GIF from 1.9 MB to 230 KB. For a 150 KB banner backup, make the GIF at the banner's own size instead.
What frame rate should a GIF use?
For interface loops and product cards, 8 to 15 fps looks smooth enough and keeps the file manageable. Use 4 fps for a Google Ads backup image, which must animate slower than 5 fps, and 24 or 30 fps only for a short clip where smooth motion is the point. Each step up adds frames, and every frame costs bytes. See the backup GIF guide for the other limits.
Trim before anything else
A GIF has no motion compensation, so its size grows with every second you keep. Cutting a 10 second clip to the 3 seconds that matter saves more than any palette or scale setting, and it shortens the wait too.
When a GIF is the wrong format
If the destination plays video, a muted, looping MP4 is usually a fraction of the GIF's size at full colour. Keep a GIF for email, chat, documentation and ad slots that only take images.
Frequently asked questions
- Is the MP4 uploaded?
- No. ffmpeg is downloaded as WebAssembly and runs in a worker in this tab. The clip is read into memory, converted there, and offered back as a download.
- How do I convert only part of the video?
- Type the start and end in seconds, such as 2 and 5.5. Leave Start empty to begin at the first frame, or End empty to run to the last. The cut is exact to the frame.
- Why is my GIF bigger than the MP4?
- Video codecs store the changes between frames; GIF stores every frame as a picture with at most 256 colours. A GIF of the same clip is often several times the MP4's size. Trim it, lower the frame rate or halve the size, as the table above shows.
- Can a GIF have sound?
- No. GIF is an image format with no audio track. If you need sound, keep the MP4.
- Why does text look speckled?
- With 256 colours per frame, antialiased edges and gradients are dithered. Larger, flat designs hold up best; footage and fine gradients show the dots first.
- Can it make a GIF from an HTML5 banner directly?
- This page converts an existing MP4. For an HTML5 banner, animation or web page, HTML to GIF records the source itself at its own size and frame rate.
Is the animation still in HTML?
RecordHTML records CSS, JavaScript, canvas and WebGL in Chrome and writes the GIF directly, at the size, frame rate and length you set.
10 credits free every month · No card needed