What Is a DMG File?

How to Open, Edit, and Convert DMG Files

Screenshot of several DMG files in macOS High Sierra

A file with the DMG file extension is an Apple Disk Image file, or sometimes called a Mac OS X Disk Image file, which is basically a digital reconstruction of a physical disc.

For this reason, a DMG is often the file format used to store compressed software installers instead of having to use a physical disc. You'll most likely only see them when downloading Mac OS software from the internet.

This macOS disk image format supports compression, file spanning, and encryption, so some DMG files might be password protected.

Versions of Mac newer than OS X 9 support DMG files, while the older Mac OS Classic uses the IMG file format for the same purpose.

DMG is also an acronym for some technology terms that aren't related to the Mac disk image file format, like Direct Mode Gateway and Diversity-Multiplexing Gain.

How to Open a DMG File on a Mac

DMG files are intended for Macs, so opening one on a Mac is very simple.

A DMG file is "mounted" as a drive and is treated by the operating system as if it were a physical hard drive, making it really easy to view its contents. The software you download for your Mac in a DMG format can be opened like any other file on a Mac, and then the setup program can be run to install the software.

How to Open a DMG File in Windows

A DMG file can certainly be opened in Windows, but that doesn't mean you can actually use anything you find within it.

For example, say a DMG file isn't just storing compressed files like images and videos but is instead holding a software program. You can extract, or open, the DMG file in Windows using one of the programs mentioned below, but you can't actually execute the program and use it like you would another Windows application. To use the same program in Windows, you need to download the Windows version, not the Mac DMG version.

However, assuming the DMG file just contains files like images or videos (which are likely in a format that's also compatible with Windows), or you want to just see what's inside the DMG file, you should have no problem using one of the below programs to view them.

Screenshot of an image file in a DMG file in Windows
Viewing the Contents of a DMG File in Windows.

Windows can open a DMG file with any compression/decompression program that supports the format. PeaZip and 7-Zip, both free, support opening DMG files in Windows.

If you have trouble opening DMG files by double-clicking them, even if you have PeaZip or 7-Zip installed, try to right-click the DMG file and use the context menu. For example, 7-Zip opens DMG files via 7-Zip > Open archive.

DMG Extractor (the paid version) is helpful if you need to do more with DMG files than just uncompress them.

SysTools DMG Viewer is great if all you want to do is look to see what's in the DMG file. Catacombae HFSExplorer can view DMG files on Windows, too (and Linux), but also lets you create new DMG files. Both programs are completely free.

A free tool called dmg2iso will convert the DMG image file to an ISO image file, which is much more usable in Windows. If you need to mount a DMG file in Windows, but don't want to convert it to ISO first, a few programs do support this, like WinCDEmu, Virtual CloneDrive, and Prismo File Mount Audit Package. Newer versions of Windows support ISO mounting natively.

How to Convert a DMG File

As we mentioned above, dmg2iso can be used to convert DMG to ISO. dm2iso is a command-line tool, so you may need to reference the download page for instructions on the syntax and other rules. Also on the download page is a DMG to the IMG tool if you need to convert the file to an IMG file instead.

AnyToISO works the same way as dmg2iso but is much easier to use. The program is free but only for files that are no larger than 870 MB.

Some free file converters can convert DMG files to a variety of other archive formats, like ZIP, 7Z, TAR, GZ, RAR, and others. CloudConvert and FileZigZag are two notable examples.

To convert DMG to PKG (a macOS installer package file) requires that you first extract the contents of the DMG file and then build a new PKG file using that data. See this this tutorial on the Spirion Support Portal if you need help.

You cannot convert DMG to EXE if you want to use the DMG file in Windows. DMG files are for Macs and EXE files are for Windows, so the only way to use a DMG program on Windows is to download its equivalent from the developer (if one exists); there aren't any DMG file to EXE file converters.

Again, just because you can extract a DMG file in Windows, or even convert a DMG to a Windows-readable format, doesn't always mean that the contents of the DMG file will suddenly become compatible with Windows. The only way to use a Mac program or a Mac video game in Windows is to download the Windows-equivalent version. If there isn't one, then neither converting nor extracting a DMG file will be of any use.

If you want to make a bootable DMG file, you don't have to worry about converting it to a USB format with any of the tools mentioned above. The whole DMG to USB process is possible with a tool like TransMac. Just right-click the USB drive in that program and then choose Restore with Disk Image, and then you can boot to the USB drive to run the DMG program.

Still Can't Open the File?

If none of the techniques mentioned above have been helpful in opening the DMG file in Windows, macOS, or Linux, there's a really good chance that you don't really have a DMG file. This might happen if the file extension has been confused for DMG.

For example, the DGML file extension looks a lot like DMG even though the two are unrelated. The former is used for Visual Studio Directed Graph Document files and opens with Microsoft's Visual Studio.

GMD is another example of a similar looking suffix that's reserved for GameMaker Program Code files and GroupMail Message files. Again, neither formats are related to the DMG Mac file format, so if your file really ends in one of those extensions, you need GameMaker or GroupMail installed in order to use the file.