MP4 to GIF Converter

Turn an MP4 video into a looping GIF, right in your browser.

or drop files here

MP

MP4 Format

MPEG-4 Part 14

A container format defined in ISO/IEC 14496-14 that can hold video, audio, subtitles and metadata. H.264 video with AAC audio is the most common combination.

  • Container for several codecs
  • H.264 video with AAC audio is the common pairing
  • Video files use .mp4 or .m4v
  • Every major browser plays MP4
GI

GIF Format

Graphics Interchange Format

A raster image format introduced by CompuServe. It uses LZW compression, a palette of at most 256 colors per frame, and supports simple animation.

  • 256-color palette per frame
  • Lossless LZW compression
  • Animation
  • 1-bit transparency

How to convert MP4 to GIF

Follow these steps to convert MP4 to GIF online.

    1

    Choose your MP4 file, or several at once.

    2

    Wait while the converter turns each file into GIF.

    3

    Download each new GIF file. Your original file isn't changed.

What to know before converting MP4 to GIF

  • The GIF is 15 fps and at most 480 px on its longer side.
  • A palette is generated from the video, because GIF allows 256 colors per frame.
  • The sound is not kept, and the GIF loops.
  • FFmpeg runs in your browser, so the video isn't uploaded.

About MP4 files

What is an MP4 file?

MP4 follows MPEG-4 Part 14, numbered ISO/IEC 14496-14 and first issued in 2003. An MP4 is a container: it wraps video, audio and other tracks instead of setting how they are compressed. Its foundation, the ISO Base Media File Format, descends from Apple's QuickTime; everything is stored in nested boxes, called atoms in QuickTime.

The usual contents are H.264 video with AAC audio, though AV1, VP9 and HEVC video, and MP3 or Opus audio, fit too. The extensions are .mp4 and .m4v for video, with .m4a common for sound alone. Every major browser plays MP4. Unisys started charging license fees for GIF's LZW coding in 1994. The American patent lapsed in 2003; those in Europe and Japan followed a year later.

Programs that open MP4 files

  • Web: Firefox plays supported media directly, but AAC and H.264 availability can follow system codecs. Chrome plays the MP4 combinations it supports, though the codec inside still decides.
  • Windows, Mac and Linux: ffplay plays MP4. mpv, a desktop player, lets you pick the audio and subtitle tracks to play.
  • Windows and Mac: when a suitable decoder is installed, Adobe Premiere accepts MP4 files.
  • Mobile: VLC for Android is a free player, and VLC for iOS handles most video formats. Android can play HEVC in MP4 from version 5.0.

MP4 and GIF compared

  • Extensions and media types: .mp4, or .m4v for some video files, with video/mp4; .gif with image/gif.
  • What's inside: an MP4 holds video and audio tracks. A GIF is a series of palette images, each followed by a pause measured in hundredths of a second.
  • Color: no frame in a GIF can use more than 256 colors.
  • Compression: an MP4 keeps whatever its codec produced, such as H.264. A GIF squeezes every image separately and losslessly with LZW.
  • Transparency: a GIF can mark a single palette color as fully clear; there is no partial transparency.
  • Sound: an MP4 can carry audio. A GIF cannot.
  • History: CompuServe released GIF in 1987. With GIF89a in July 1990 came transparency, timing between frames and application data.

What this converter does: it deinterlaces interlaced video, samples 15 frames per second, and scales the picture to fit within 480 pixels on its longer side, keeping both sides even. A single palette is then built from the clip, every frame is mapped to it, and the GIF is set to loop forever. The audio is left behind.

Other ways to convert MP4 to GIF

  • Adobe Photoshop: use File > Import > Video Frames to Layers, make a frame animation from the layers in Window > Timeline, then export through File > Export > Save for Web (Legacy) as a GIF set to loop Forever. A long video may not import in full.
  • Microsoft Clipchamp: put the video in a project, press Export at the top right and select GIF. The option is offered only for videos of 15 seconds or less.
  • FFmpeg (command line): run ffmpeg -i input.mp4 output.gif. A GIF frame delay can't be under a hundredth of a second, and the output loops forever unless -loop says otherwise. This page runs FFmpeg too, with a palette built from your clip.

Problems with MP4 files

  • It won't play: an MP4 may hold video or sound your player has no decoder for. Try another player, such as mpv.
  • "FFmpeg failed with exit code N" appears: the conversion didn't finish. Try another copy of the video.
  • A cut-short video gives a short GIF: a damaged or truncated video can still convert, and the GIF then holds what FFmpeg managed to read.
  • The colors look coarse: no frame can use more than 256 colors, so the palette built from your video can't keep every shade.
  • The GIF holds the whole video: there is no trim step, so cut the clip to the moment you want before converting.
  • A long video takes ages: everything runs on your device with no time limit, so a long clip needs more patience.
  • The motion looks choppy: the GIF samples 15 frames per second, so fast action moves in visible steps.
  • The GIF is smaller than the video: scaling stops at 480 pixels on the longer side, and a smaller video isn't scaled up.
  • Your video is a .mov: use the MOV to GIF converter.

Frequently Asked Questions

Everything you need to know about our converter

What size and frame rate is the GIF?

Does the GIF loop and have sound?

Why do the colors look different in the GIF?

Can I make a GIF from a long MP4?

Can I make a larger or smoother GIF than this page does?

Is it possible to convert a batch of MP4 videos?

Can I convert only part of the video?

What happens to a vertical phone video?

What happens to interlaced video?

Can I use a .mov file here?