MPEG
MPEG (MPEG-1/MPEG-2 program stream) is the format behind Video CDs, DVDs, and broadcast capture cards. It is extremely widely decodable and a safe choice for DVD authoring or older hardware players, but the compression is decades behind H.264 — expect much larger files for the same picture.
MP4
MP4 (MPEG-4 Part 14) is the most widely supported video container on the planet. It packs H.264 or H.265 video with AAC audio into a single file that plays natively on iPhone, Android, Windows, macOS, web browsers, smart TVs, and every modern editor. Use MP4 when you need a finished, shareable video that will just work, anywhere, without re-encoding.