Manatee

How to convert a DivX or Xvid AVI to MP4 on a Mac

Converting a DivX or Xvid AVI to MP4 makes an old video that modern Macs stumble over play cleanly in QuickTime, Photos, and on a phone. Both DivX and Xvid are versions of the same older MPEG-4 video codec wrapped in an AVI file, and the reliable fix is to re-encode the video to H.264 inside an MP4 container. The quickest way is to drop the AVI onto a converter, choose MP4, and let it rebuild the video into a format Apple devices actually decode. This post explains why these files misbehave and how to convert them well.

What DivX and Xvid AVI files really are

AVI, Audio Video Interleave, is a container Microsoft introduced in the 1990s. DivX and Xvid are not containers; they are video codecs, two implementations of MPEG-4 Part 2, the compression that made it possible to fit a full movie onto a CD back when that mattered. If you have a folder of downloads or ripped discs from fifteen or twenty years ago, a lot of them are Xvid or DivX video inside an AVI, usually with MP3 audio.

They were everywhere for a reason: for their day, the quality-to-size ratio was excellent. The trouble is that the world moved on to H.264 and HEVC, and Apple quietly dropped the old codec support. Modern QuickTime Player often refuses to open an Xvid AVI, or opens it with no video, and Photos will not import it. There is no reliable built-in way on a current Mac to play or convert these files, which is why they feel stranded.

Why a straight copy is not the safe route

MP4 can technically hold MPEG-4 Part 2 video, so in principle the DivX or Xvid stream could be copied into an MP4 without re-encoding, and MP3 audio can ride along in MP4 unchanged. In practice this is a trap. QuickTime and iPhones do not reliably decode MPEG-4 Part 2, so a copied-over file would still refuse to play on the very devices you are converting for. Worse, DivX files often use a trick called packed bitstream that confuses players and causes stutter or frozen frames unless it is unpacked.

The dependable answer is to re-encode the video to H.264, the codec every Apple device decodes in hardware. Yes, re-encoding is technically a small quality loss, because the video is decoded and compressed again. But these are old, already heavily compressed files, and a good H.264 encode at a sensible quality setting preserves everything the source actually contains. You are not going to see the difference; you are going to see a file that finally plays.

The audio usually needs no drama. MP3 can stay in the MP4 as it is, so the sound is copied without loss while the video is rebuilt.

How to convert a DivX or Xvid AVI to MP4 on a Mac

The open-source ffmpeg engine handles these files well from Terminal. It is not installed on macOS by default; a package manager adds it in a moment. Type ffmpeg -i, drag the AVI onto the window, then add -c:v libx264 -crf 20 -preset slow -c:a copy ~/Desktop/movie.mp4 and press Return. That re-encodes the video to H.264 at a high quality setting and copies the MP3 audio untouched. If playback ever stutters, adding -bsf:v mpeg4_unpack_bframes before the output name clears the packed-bitstream problem, though a full re-encode usually sidesteps it anyway.

If you would rather not type commands, Manatee does the same conversion from its window or the menu bar icon:

  1. Open Manatee and choose Convert.
  2. Pick MP4 as the target.
  3. Drop the AVI in, or a whole folder of old clips. Each appears in the job list with progress.
  4. The MP4 is written next to the AVI, and the original is left alone.

Manatee re-encodes the aging Xvid or DivX video to H.264 and keeps the audio, producing an MP4 that plays in QuickTime and on phones without you touching a command line. It runs entirely on the Mac, uploads nothing, and bundles its own copy of ffmpeg, so there is nothing to install. It converts rather than edits, so if you also want to trim or join clips, do that in other software afterward.

Quality, batches, and old-file quirks

Because a re-encode is unavoidable here, the quality setting is the thing to get right. A high-quality H.264 encode keeps every detail the source holds; pushing compression harder to save space starts to smear the already-soft picture of an old clip. Convert once, at good quality, from the original AVI rather than from a copy that has been through another tool, so the footage is compressed only one more time.

If you are clearing out a large archive, convert the whole folder in one batch and let each file run through in turn rather than doing them one by one. When a finished MP4 needs to be smaller for sharing, shrink it as a single deliberate step from the good file, not repeatedly.

A couple of old-file realities are worth expecting. Some ancient AVIs have a variable or unusual frame rate that can make the converted file play slightly fast or slow; a good converter normalizes this, but if a clip looks off, that is the likely cause. And a small number of AVIs from the download era are genuinely damaged partway through, which is a repair problem rather than a conversion one; a converter that also repairs can often salvage the playable portion.

Questions

Why will QuickTime not play my Xvid or DivX AVI?

Because modern macOS dropped support for the old MPEG-4 Part 2 codec these files use. The file is not necessarily broken; the built-in players just no longer decode that codec. Converting the video to H.264 in an MP4 fixes it.

Can I convert without any quality loss?

Not reliably. Copying the old codec into an MP4 avoids re-encoding but leaves you with a file Apple devices still will not play, so re-encoding to H.264 is the practical choice. On these already-compressed old clips, a high-quality encode looks identical to the source.

Will my MP3 audio survive the conversion?

Yes. MP3 is supported inside MP4, so the audio can be copied over unchanged while only the video is re-encoded. Your sound is not touched.

The converted video plays too fast or too slow. What happened?

Some old AVIs carry an unusual or variable frame rate that trips up a naive conversion. Reconverting with a tool that normalizes the frame rate fixes the timing so the picture and audio run at the right speed.