WEBM to GIF
Published Updated
Choose your frame rate and target width, then convert your WEBM video into a downloadable animated GIF — free, private, and processed entirely in your browser.
WebM in, looping GIF out
This page converts .webm files, the format Chrome, Edge and Firefox usually write when a web page records a screen, a tab or a camera. The tool samples the clip frame by frame and builds a GIF that loops forever, with up to 450 frames, sampled at 5, 10 or 15 fps and scaled to 320, 480 or 640 px wide.
WebM is a subset of the Matroska container and carries VP8 or VP9 video (WebM container guidelines). Your browser does the decoding, so a clip that plays in the preview is a clip this tool can read. Clips from the Screen Recorder on this site work the same way.
Three settings that decide the result
- Frame rate. 10 fps is smooth enough for menus, clicks and typing. 15 fps costs half again as many frames and is only worth it for scrolling or animation. 5 fps suits slow demos.
- Width. The output is never wider than the source and keeps its aspect ratio. A 1280 × 720 recording becomes 320 × 180, 480 × 270 or 640 × 360. For small interface text, 480 or 640 px stays legible and 320 px often does not.
- Length. Time and file size both grow with the number of frames, and a 20-second clip at 10 fps is 200 frames. At 480 × 270 that is 25.9 million palette entries before compression, so trim the recording before you convert if you can.
From WebM to GIF in three steps
Step 1
Add a .webm file
Pick a clip such as a screen or tab recording. The page shows its length and pixel size once the browser has read it.
Step 2
Choose frame rate and width
For screen captures with small text, 480 px at 10 fps is a sensible start. Use 15 fps only for fast motion.
Step 3
Convert, then compare
The result card reports frames, pixel size and file size. If it is too heavy, change one setting and convert again.
Why some recordings convert slowly
A file written live by a recorder cannot know its own length in advance, so many have no duration in the header. WebM files are also meant to carry a Cues index of keyframes so players can jump around quickly, and live-written files often lack it. The converter jumps to a new time for every frame, so a recording without that index can take much longer to convert than its length suggests.
If a conversion drags, shorten the clip, lower the Frame rate. How many pictures are shown per second, written fps. A GIF stores each frame's delay in hundredths of a second, so 10 fps is a 10-hundredths delay and 15 fps has to round to 7 hundredths, which plays at about 14.3 fps. Read the guide or pick a smaller width. All three reduce the number of seeks or the work done per frame.
What the converter does with a WebM
The clip goes into a hidden video element. Once the browser reports its size, the tool works out the frame count as the clip length times the frame rate, rounded up and capped at 450. For frame number i it seeks to i divided by the frame rate (never past the end), draws the picture onto a canvas at the chosen width, and keeps the pixels. When all frames are in, they are quantized to one shared palette of up to 256 colors and written as a looping GIF.
When Google Chrome has no known length for a WebM, the duration comes back as Infinity (MDN, HTMLMediaElement duration). The tool then seeks to a huge time to make the browser find the end, waits for a duration change, and rewinds, as the FAQ below describes. A WebM that Firefox recorded with MediaRecorder reported an infinite length in Google Chrome 158; the tool converted it at 10 fps to 30 frames, which fits its 3-second length.
Worked example: a 4-second VP8 test clip
The clip was generated by a script: 100 frames at 25 fps, 640 x 480, a smooth gradient with a moving disc and a progress bar whose length encodes the frame number. It was encoded to VP8 in a WebM file of 712,706 bytes. This page's own tool converted it in Chrome 158, one run per row.
| Setting | Frames | GIF size | Delay per frame, in the file | Time to convert |
|---|---|---|---|---|
| 10 fps, 640 px | 40 (640 x 480) | 1,543,012 B | 10 hundredths of a second | 3.5 s |
| 10 fps, 320 px | 40 (320 x 240) | 664,543 B | 10 | 3.0 s |
| 5 fps, 320 px | 20 (320 x 240) | 328,348 B | 20 | 1.5 s |
| 15 fps, 480 px | 60 (480 x 360) | 1,638,833 B | 7 | 4.3 s |
To check that each frame came from the right moment, we read the progress bar in every GIF frame and compared it with the frame expected at that timestamp. In all four runs every frame matched: 40 of 40, 40 of 40, 20 of 20 and 60 of 60. The 15 fps GIF holds 60 frames at 7 hundredths of a second, so it plays for 4.2 s although the clip lasts 4.0 s, because delays are stored in whole hundredths of a second (GIF89a specification).
The GIF is 1.5 MB at 10 fps and 640 px, more than twice the 0.7 MB WebM, with 40 of its 100 frames. Time grows with the number of frames: 1.5 s for 20 frames, 3.0 to 3.5 s for 40 and 4.3 s for 60. A different machine will give different times.
Edge cases and limits
- For a file the browser cannot decode, the line under the preview shows an error message. The message was seen with a junk .webm file (50,000 random bytes) in Chrome 158, Firefox 155 and Playwright's WebKit build (not the Safari app).
- Frames are held in memory as raw pixels before encoding. The cap of 450 frames at 640 x 480 is 553 million bytes (450 x 640 x 480 x 4).
- A seek that finishes late is abandoned after 3 seconds and the picture on screen is drawn, which can repeat a frame. We saw no repeated frame in the four runs above.
- The width is never larger than the clip's own width, so a 480 px wide recording stays 480 wide at the 640 setting.
WebM to GIF, answered
How long can the WebM clip be?
The limit is 450 frames per GIF, so the longest clip is 450 divided by the frame rate: 90 seconds at 5 fps, 45 at 10 fps and 30 at 15 fps. Sampling always starts at 0:00 and anything beyond the cap is left out.
My recording has no duration in its header. Will it convert?
Yes. When the browser first reports the length as zero, unknown or infinite, the converter waits up to 3 seconds for the real length, seeking to the end of the file and back first when it is infinite, and then samples frames.
Why do two neighbouring frames look identical?
For each frame the tool waits for the browser to finish seeking, but only for 3 seconds. After that it draws whatever is on screen and moves on, which can repeat a frame in files that seek slowly.
Does the sound from my screen recording carry over?
No. GIF cannot hold audio, so the result is a silent picture.
Should I share the WebM or the GIF?
Share the WebM whenever the destination plays video. The GIF is the fallback for places that only take images, and for clips of a few seconds it is the easier choice.
Why does my GIF play slightly slower than the WebM?
At 15 fps each frame gets a delay of 7 hundredths of a second, which is a little longer than 1/15 s. In our test 60 frames played for 4.2 s from a 4.0 s clip.
Why can the GIF be bigger than my WebM?
A WebM usually stores changes between frames. A GIF here stores every frame whole. Our 712,706 B test clip gave 328,348 B at 5 fps and 320 px and 1,543,012 B at 10 fps and 640 px.
Nothing happens after I pick my WebM. Why?
If the browser cannot read the clip, the line under the preview turns into an error message. A junk .webm file gave a message saying that the browser cannot read the file because its format or codec is not supported or the file is damaged, in Chrome 158, Firefox 155 and the WebKit build. If you see no message, the browser may still be reading the file.
Related guides
Making a GIF from a video: size, frame rate and quality. The guide describes how frame count scales with clip length and what a long recording costs in size.
MP4, MOV and WebM: which video format to use and how to convert. The guide converts a 4-second WebM at 320 px wide: 244,614 to 276,073 bytes at 10 fps and 133,248 to 137,755 at 5 fps, with WebKit taking 13.1 seconds to capture.