A sparse bundle is a macOS disk image format that stores a virtual disk as a package folder of many small band files instead of one large file, so the image occupies only the space its data actually uses and can grow up to a maximum size set at creation. In macOS storage & backup, the sparse bundle (file extension .sparsebundle) is best known as the container Time Machine uses for network backups, and it is also a practical way to keep an encrypted, resizable volume on a shared drive or in a synchronized folder.
Apple introduced the format in Mac OS X 10.5 Leopard as the successor to the single-file sparse image. Inside the bundle sits an ordinary file system, today usually APFS or HFS+, which macOS mounts like any other disk once the image is opened.
How a sparse bundle stores data in bands
A sparse bundle splits the virtual disk into fixed-size chunks called bands, and each band is written to disk only when the file system inside the image first uses that region. The bundle is a directory that the Finder displays as a single item, but in Terminal it reveals a small set of files and a bands subfolder.
The default band size is 8 MiB (16,384 sectors of 512 bytes). A band file is named with a hexadecimal number that matches its offset in the virtual disk, so band 0 covers the first 8 MiB, band 1 the next 8 MiB, and so on. Regions that were never written simply have no band file, which is what makes the image sparse.
The following table lists the main components found inside a typical bundle and what each one does.
| Component | Purpose | Typical size |
|---|---|---|
| Info.plist | Stores format version, band size and maximum image size | Under 1 KB |
| Info.bckup | Backup copy of Info.plist used for recovery | Under 1 KB |
| token | Holds encryption header data or remains empty | 0 bytes to a few KB |
| bands folder | Contains the band files with the actual disk data | Grows with use |
| lock | Prevents two hosts from mounting the image at once | 0 bytes |
Because changes touch only the bands that hold modified blocks, incremental copying is efficient. A backup tool or sync client that compares files sees a handful of changed 8 MiB bands rather than one multi-gigabyte image that changed somewhere inside.
Sparse bundle versus other macOS disk image formats
The sparse bundle is one of several image formats that Disk Utility and the hdiutil command can create, and the right choice depends on whether the image must grow, travel as one file or stay read-only. The read-only compressed image commonly distributed as a DMG is a different use case: it packages finished content, while a sparse bundle holds a writable volume that keeps changing.
The table compares the formats a Mac user meets most often.
| Format | Type in hdiutil | Structure | Grows on demand | Best suited for |
|---|---|---|---|---|
| Sparse bundle | SPARSEBUNDLE | Folder of band files | Yes | Network backups, synced encrypted volumes |
| Sparse image | SPARSE | Single file | Yes | Local growable volumes |
| Read/write image | UDRW | Single file | No, full size at once | Fixed working volumes |
| Compressed image | UDZO or ULFO | Single file | No, read-only | Software distribution |
The single-file sparse image also grows on demand, but any change rewrites parts of one large file, which forces many sync and backup tools to copy the whole file again. That difference is the main reason Apple adopted the bundle format for networked Time Machine destinations.
Why Time Machine uses sparse bundles on network destinations
Time Machine places backups inside a sparse bundle whenever the destination is a network share such as a NAS over SMB, because the backup needs a Mac file system with features that the server file system does not provide. The server stores only plain band files, while macOS mounts the bundle and writes to the APFS or HFS+ volume inside it.
On a directly attached drive, current macOS versions format the disk itself as APFS and use no sparse bundle. Since macOS Big Sur, new network backups also use APFS inside the bundle, which enables snapshot-based backups, while older backups created on HFS+ keep that file system. The bundle name usually matches the computer name, and a com.apple.TimeMachine.MachineID.plist file inside ties it to the specific Mac.
The bundle structure brings real benefits and real risks for backups, summarized below.
| Aspect | Benefit | Risk |
|---|---|---|
| Storage use | Consumes only space that holds data | Freed space is not returned without compaction |
| Network writes | Only changed bands travel over the network | An interrupted write can leave bands inconsistent |
| Server compatibility | Works on file systems without Mac metadata | Depends on stable SMB locking and caching |
| Encryption | AES encryption protects data at rest on the server | A lost password makes the backup unrecoverable |
When macOS detects damage, Time Machine may report that it must create a new backup, which discards the history. Stable networking, a wired connection for the first large backup and a NAS with reliable power reduce that risk considerably.
Creating, resizing and compacting a sparse bundle
A sparse bundle can be created in Disk Utility through File, New Image, Blank Image with the image format set to sparse bundle disk image, or in Terminal with hdiutil create -type SPARSEBUNDLE -size 200g -fs APFS -volname Archive Archive.sparsebundle. The -size value sets the maximum capacity, not the space used at creation.
The most useful maintenance operations and their commands appear in the next table.
| Task | Command or method | Notes |
|---|---|---|
| Create with encryption | hdiutil create -encryption AES-256 ... | AES-128 is faster, AES-256 is the stronger option |
| Raise the maximum size | hdiutil resize -size 500g image.sparsebundle | Expand the inner volume afterward if required |
| Reclaim free space | hdiutil compact image.sparsebundle | Image must be unmounted first |
| Change band size | -imagekey sparse-band-size=... at creation | Value is given in 512-byte sectors |
| Check the inner volume | Disk Utility First Aid on the mounted volume | Repairs the file system, not the bands |
Compaction matters because deleting files inside the mounted volume does not automatically delete band files. Running hdiutil compact removes bands that no longer hold data and can return many gigabytes on images with heavy turnover. Larger bands reduce the file count on the host, while smaller bands make incremental sync more granular.
Limitations and common mistakes
A sparse bundle is robust when it is accessed by one Mac at a time over a reliable connection, and fragile when that assumption is violated. Most corruption reports trace back to a few recurring errors.
- Opening the same bundle from two Macs at once; the lock file helps, but some network shares do not honor it reliably.
- Syncing a mounted image with a cloud client, which can upload half-written bands and leave an inconsistent copy.
- Copying single band files to restore data; bands are meaningful only as a complete set inside the bundle.
- Expecting automatic shrinking after deleting data; the bundle stays large until it is compacted.
- Forgetting the encryption password; there is no recovery path without the password or a stored keychain item.
Sparse bundles are specific to macOS. Windows and Linux can see the band files on a share but cannot mount the image natively, so the format is unsuitable for exchanging data across platforms.
Explained without jargon
Think of a sparse bundle as a binder of loose pages that pretends to be a whole disk. The binder starts nearly empty, and a new page is added only when something needs to be written. Your Mac opens the binder and shows it as a normal drive.
Because the disk is split into many small pages, a change touches only a few of them. That is why copying it over a network is fast and why Time Machine likes it for backups to a shared drive. The key point is simple: it grows when you add data, but it does not shrink by itself when you delete data.
A typical use case
A small design studio keeps a NAS in its office and backs up five Macs to it with Time Machine over SMB. Each Mac gets its own sparse bundle with a 1 TB quota, and the studio enables backup encryption so that the files on the NAS are unreadable without each user’s password.
A designer’s Mac changes about 3 GB of project files per day. Instead of rewriting a large image, Time Machine updates only the bands that hold those changed blocks, so hourly backups over the office network finish in a few minutes. Once a quarter, the administrator checks the bundle sizes and compacts an archive bundle that has accumulated deleted data, which recovered roughly 180 GB of NAS space in the last cycle.