Convert GIF to MP4

Turn animated GIFs into small MP4 videos that post and play anywhere. Converted on this device, never uploaded.

Converts animated GIFs to MP4 video (H.264 in Chrome, Edge and Safari, with no sound track since GIFs have none), often five to twenty times smaller, with each frame keeping its timing. It is free, and your GIFs are not uploaded: each frame is encoded by your browser’s own video encoder. The size limit is your device’s memory (phones hold less), and after one visit and a short wait the page works offline.

Drop GIFs to convert to MP4or click to choose files. Batches welcome.
    Details

    A video plays once, where a GIF loops. Short loops are repeated so Instagram, WhatsApp and other apps accept them.

    Working…

    Done

    Your files are processed on this device and never sent to a server. Reload the page to clear everything from memory.

    How it works

    1. Drop one or more animated GIFs, or tap to pick them.
    2. Choose how long the video should be: short loops are repeated to at least 3 seconds so apps accept them, or pick a number of plays. Choose what transparent areas become.
    3. Convert. Each GIF is encoded to MP4 in your browser; one downloads straight away, several download as a zip.

    In your browser, not on a server

    Stayput reads the GIF byte by byte in your tab with gifuct-js (MIT), decompresses each frame and composites it the way browsers play GIFs, honouring each frame’s delay and disposal rule. Every finished frame goes to your browser’s own video encoder through WebCodecs: H.264 where the browser has one (Chrome, Edge, Safari), VP9 or AV1 where it does not. The encoded frames are written into an MP4 container by mp4-muxer (MIT), all in memory.

    Compared with upload-based tools: GIF to MP4 sites upload the file to convert it on a server, cap the size, and some add a watermark or keep the file for hours. Here the conversion runs on your device, so a reaction GIF, a screen recording of your product or a clip of your kids never leaves it, and the page keeps working offline after one visit and a short wait.

    Verify it yourself. Give the page a short while after one visit to save itself for offline use, then turn off Wi-Fi or switch to airplane mode and run the tool again. Or open your browser's developer tools (F12, or Cmd-Option-I on a Mac), pick the Network tab, and watch it while you convert. The panel above does the same count for you.

    Questions

    Is my GIF uploaded?

    No. The GIF is decoded by code in this page and each frame is encoded by your browser’s own video encoder. There is no server in the process, so there is nothing to wait for, and after one visit and a short wait the page works with Wi-Fi off.

    Why is the MP4 so much smaller than the GIF?

    GIF compresses each frame on its own, with at most 256 colours. MP4 video stores only what changes from one frame to the next, so the same animation is often five to twenty times smaller, and it keeps its full colours. That is why sites such as X, Reddit and Giphy quietly turn uploaded GIFs into MP4.

    Will the video loop?

    A video file plays once; looping is up to the player. Most chat apps and social sites loop short videos automatically. If you need a fixed length, pick how many times the animation plays, or keep the default, which repeats short loops to at least 3 seconds (Instagram rejects shorter videos).

    Does it keep the timing of each frame?

    Yes. Every frame keeps its own delay from the GIF, so slow-downs and pauses play as they did. Frames with a delay of 0 or 1 hundredths of a second are shown for a tenth of a second, which is what every browser does with them too.

    Which video format do I get?

    An MP4 with H.264 video, the format every phone, laptop, social site and PowerPoint plays, in Chrome, Edge and Safari. A browser without an H.264 encoder (some Linux builds) writes VP9 in the MP4 instead, which browsers and Android play but older iPhones may not; the result says which one you got. There is no sound track, since GIFs have none.

    More video and audio tools

    Popular conversions

    Guides