# macOS: hdiutil: attach failed - image not recognized / no mountable file systems

**Code:** `hdiutil: image not recognized / no mountable file systems` · **Category:** macOS · **Seen on:** macOS

The `.dmg` file is corrupted, incomplete, or not actually a disk image (often an HTML download page).

## Meaning

Check size and type: `file app.dmg`. A tiny file or "HTML document" means the download failed (blocked, login page). Re-download, verify checksum, and try `hdiutil verify`. Encrypted or unusual formats need the right tool/password.

## Common causes

- Interrupted/incomplete download
- Server returned HTML error page named .dmg
- Corrupted file after transfer
- Wrong file type (zip/pkg renamed)
- Unsupported/encrypted image

## Quick fix

1. `file app.dmg` and compare size
2. Re-download over a stable connection
3. `hdiutil verify app.dmg`

## Detailed fix by platform

### macOS

1. `file app.dmg && shasum -a 256 app.dmg && hdiutil verify app.dmg`

## How to diagnose

1. **Type** — file says disk image?
2. **Size** — Expected?
3. **Checksum** — Match?

---
Source: [WhatIsMyError](https://whatismyerror.com/errors/macos/dmg-image-not-recognized)
