What Is a .DMG File?

A .dmg file is an Apple disk image, the usual way Mac apps are distributed outside the App Store. Double-clicking it mounts it like a virtual drive in Finder, where you typically drag the app into the Applications folder. DMGs can be compressed and encrypted, and only Macs open them natively.

Extension
.dmg
Full name
Apple Disk Image
Type
System and app file
MIME type
application/x-apple-diskimage
Developed by
Apple

About DMG files

A DMG behaves like a USB drive: once mounted it appears in Finder's sidebar and on the desktop. Many show a window with the app icon and an arrow to Applications. Running the app directly from the mounted image works but is not recommended; copy it to Applications, eject the image and delete the DMG.

Gatekeeper checks apps from DMGs. Apps from identified developers that Apple has notarized open after a confirmation; others are blocked. Since macOS Sequoia, the Control-click Open shortcut no longer overrides this, and you must go to System Settings > Privacy & Security and click Open Anyway. Do that only for software you trust; fake DMGs for popular apps are a common way Mac malware spreads.

DMGs can be read-only, compressed or encrypted with a password, and Disk Utility can create them to back up or share folders. Windows has no built-in DMG support, but 7-Zip can extract many DMG files, which is useful only for retrieving documents, since Mac apps will not run on Windows.

What DMG files are used for

  • Installing Mac apps downloaded from developer websites
  • Distributing macOS installers and updates
  • Creating encrypted containers for private files
  • Archiving folders as a single image with Disk Utility

How to open a .dmg file

Mac

Double-click to mount it, drag the app to Applications, then eject the image in Finder and delete the DMG.

Windows

Mac apps cannot run on Windows. To extract documents from a DMG, open it with 7-Zip.

iPhone and iPad

DMG files cannot be opened on iOS or iPadOS.

How to convert a .dmg file

To make an ISO from a DMG on a Mac, run hdiutil convert file.dmg -format UDTO -o file in Terminal and rename the resulting .cdr to .iso.

To create a DMG from a folder, open Disk Utility and choose File > New Image > Image from Folder.

Renaming .dmg to .iso or .exe does not convert it.

Changing the extension in the file name does not convert the file. See how to change a file extension for when renaming is safe.

Naming and renaming DMG files

  • Include the app name, version and chip architecture when you keep installers (myapp-2.4.1-arm64.dmg) so you install the right build on Apple silicon or Intel Macs.
  • For encrypted backup images, include the date and contents in the name, because you cannot see inside without the password.
  • Delete installer DMGs after installing; they are no longer needed and can fill the Downloads folder.

Renaming lots of .dmg files? Use the free online bulk renamer for patterns and numbering, or try File Renamer AI to name each file from what is inside it.

Related file types

Frequently Asked Questions

How do I install an app from a DMG file?

Double-click the DMG, drag the app into Applications, eject the image and open the app from Applications.

Why does my Mac say the app cannot be opened?

Gatekeeper blocked it because it is not notarized. If you trust it, go to System Settings > Privacy & Security and click Open Anyway.

Can I open a DMG file on Windows?

7-Zip can extract many DMGs, but Mac apps inside will not run on Windows.

Can I delete a DMG after installing?

Yes. Once the app is in Applications, eject the image and delete the DMG.

More system and app file extensions · all file extensions