Skip to content
Convert

Convert AVI to MP4 online

Open an AVI from an old camcorder, a Windows archive or a DivX-era download and get back an H.264 MP4 that plays on a phone, in a browser and in a modern editor. The whole conversion runs inside this page; the file is never uploaded.

Drop your video here

or click to browse — MP4, MKV, MOV, WebM, AVI and more

How to convert AVI to MP4 in your browser

  1. 01

    Open the file

    Drag your AVI onto the drop zone above, or click it and pick the file. If a dragged file appears to do nothing, click the drop zone and choose it instead — the drag handler only accepts files your operating system has labelled as video, and it labels some AVI files as nothing at all. Either way it is read straight off your disk into the browser tab; nothing is sent anywhere.

  2. 02

    Check that MP4 is selected

    The Output format control below the timeline is already set to MP4 on this page. Read the note directly below these steps first: the editor needs your browser to report the length of the file before it shows the conversion controls, and browsers cannot read an AVI.

  3. 03

    Optionally cap the resolution or mute

    Max resolution caps the height at 1080p, 720p or 480p (it never upscales), and Mute audio drops the audio track. Both are optional and both are applied in the same pass as the conversion.

  4. 04

    Press Convert video

    With no cuts or speed changes queued, the apply button reads "Convert video". Press it. The first run downloads the ~32 MB FFmpeg engine, which the browser caches for next time.

  5. 05

    Download

    When the encode finishes a download link appears with the size of the finished file next to it. Compare it against the original before you delete anything.

Known limitation: AVI cannot be converted here right now

Being straight with you about a current limitation. The editor works out how long your file is by handing it to the browser's own video element, and it only shows the output format, resolution, mute and Convert controls once it gets a length back. No browser can read an AVI, so that length never arrives and those controls stay hidden — which means this page cannot presently convert an AVI, however well FFmpeg itself would cope with the file. This is a known bug in the editor rather than anything about your file, and the rest of this page is here because the background on AVI is worth having. Until it is fixed, VLC (Media > Convert / Save) will do the job on a desktop, as will ffmpeg -i in.avi -c:v libx264 -crf 23 -c:a aac out.mp4 if you have FFmpeg installed.

Where AVI files come from

From the past, mostly. AVI is Microsoft's 1992 container, and it was the default for a long stretch of consumer video: standard-definition camcorders that wrote DV or MJPEG, early digital cameras' video mode, Windows Movie Maker exports, and the entire DivX and Xvid era of downloaded film. If you are digging through a hard drive of family footage from the 2000s or an archive of old captures, AVI is what you find.

Very little made today plays it. No browser will, phones will not, and while VLC and desktop players still handle most AVIs, the codecs inside — MPEG-4 Part 2 (DivX/Xvid), MJPEG, DV, sometimes uncompressed or Cinepak — are ones modern hardware decoders and web players never learned. An H.264 MP4 is the format that will still open in twenty years, which is usually the point of converting an archive at all.

What changes, and why AVI is awkward

AVI is a RIFF container from before B-frames, variable frame rate and long files were things anyone had to think about. It has no real per-frame timestamps — frames are assumed to arrive at a constant rate — and no native way to store a frame that references a frame from the future, so DivX-era encoders resorted to a hack called "packed bitstream" to squeeze B-frames in. Files larger than 2 GB needed the OpenDML extension. Modern demuxers cope, but every one of those quirks is a place where a naive conversion can produce judder, a wrong duration or audio drift.

Here FFmpeg decodes whatever the AVI holds, rebuilds proper timestamps, and writes H.264 with libx264 (ultrafast, CRF 28) and AAC audio into an MP4. (If mute is the only change, the editor first tries to copy the video stream into the MP4 unchanged and re-encodes only when that fails — for a DivX AVI that can succeed and leave you with an MPEG-4 Part 2 MP4, so add a resolution cap or a cut if you want the H.264 re-encode.) Interlaced DV or camcorder footage is not deinterlaced — the frames are encoded as they are — so combing on fast motion will still be there. That is a limitation worth knowing about before converting a large tape archive.

MP3 or PCM audio, which is what most AVIs carry, becomes AAC. Only the first audio stream is kept.

Quality and file size

Old AVIs are usually standard definition — 640×480, 720×576 or smaller — which makes them tiny work for a modern CPU: a full-length DV capture converts far faster than a few minutes of 4K phone video. Size depends entirely on what was inside. A DivX file at a typical 2000s bitrate re-encoded at CRF 28 comes out roughly comparable, sometimes larger because ultrafast is not thrifty. A DV or MJPEG AVI, which is barely compressed, shrinks by a very large factor.

The Max resolution control is not much use here — it only ever scales down, and a 480p source is already below every tier. Leave it on Original.

Is a lossless remux possible? Usually not

ffmpeg -i in.avi -c copy out.mp4

On paper, MP4 can hold MPEG-4 Part 2 video and MP3 audio, so -c copy sometimes produces a valid file from a DivX or Xvid AVI. In practice it disappoints. Packed B-frames have to be unpacked first (-bsf:v mpeg4_unpack_bframes), and even when the remux succeeds you have an MP4 that browsers, phones and most hardware still cannot decode, because they support H.264 in MP4, not MPEG-4 Part 2. MJPEG, DV and uncompressed video do not belong in MP4 at all.

So for AVI the re-encode is not a compromise, it is the job. If the source is an irreplaceable archive, convert it here and keep the AVI too; the MP4 is a playable copy, not a replacement for the original.

What stays the same on every conversion here

Nothing is uploaded. The file is read from your disk into the tab, FFmpeg compiled to WebAssembly does the decode and the encode there, and the result is handed back as a download. What does and does not leave your device is spelled out in full. There is no account, no watermark and no size cap other than the memory of the device you are on, since the whole file lives in RAM while it is being worked on.

The first conversion downloads the engine, roughly 32 MB, which the browser caches afterwards. Where SharedArrayBuffer is available the multi-threaded core is used and the encode runs across your CPU cores; otherwise a single-threaded build takes over and the same job takes several times longer. How it works walks through the pipeline, and the FAQ covers the rest.

Questions about converting AVI to MP4

Why is there no preview when I open an AVI?
The preview is your browser's own video element and browsers have never supported AVI. Unfortunately the editor also takes the length of the file from that same element, and it only reveals the output format, resolution, mute and Convert controls once it has a length. With an AVI it never gets one, so those controls stay hidden and the conversion cannot currently be started here. That is a known bug on our side, not a problem with your file; use VLC or FFmpeg on a desktop in the meantime.
Will my old DivX or Xvid AVI convert?
Almost always. MPEG-4 Part 2 decoding, including packed-bitstream files, is a core part of FFmpeg and is included in this build. MJPEG and DV camcorder AVIs convert too. An AVI using a genuinely obscure codec from a long-dead capture card may not decode; the log shows what FFmpeg saw.
Does converting AVI to MP4 improve the quality?
No. Conversion cannot add detail that was not in the source; CRF 28 H.264 preserves what is there at one generation of loss. Interlaced camcorder footage is not deinterlaced either. What you gain is a file that plays everywhere and will keep playing.
Can I convert a large AVI archive file?
Yes, subject to your device's RAM, because the file is held in memory in the tab. Standard-definition AVIs, even long ones, are fast to convert compared with modern high-resolution video. Nothing is uploaded, so there is no server-side size cap.
Is a lossless AVI to MP4 conversion possible?
Rarely in any useful way. MP4 can technically hold the MPEG-4 Part 2 video from a DivX AVI, but the players you are converting for do not decode that codec in MP4 anyway, and DV or MJPEG cannot be remuxed at all. A re-encode to H.264 is the practical answer.

Other conversions

All converters · Supported formats · Free online video editor

Guides on re-encoding and remuxing

What to do when the file will not open at all, why a filtered stream has to be re-encoded, the command-line remux that avoids it, and what happens when the file is very large.

All video editing guides