tmutil — Control Time Machine Backups

Practical guide to tmutil: control Time Machine from the command line — start backups, manage snapshots, set destinations and restore files.

tmutil controls Apple's Time Machine straight from the command line – you start and stop backups, set backup destinations, manage local APFS snapshots and restore individual files without going through System Settings. That makes it especially handy for scripts, maintenance routines and headless server Macs without a logged-in user. This guide walks you through the subcommands you reach for daily, from backup control to targeted restores.

Backup Control

tmutil startbackup — Start a Time Machine backup immediately.

sudo tmutil startbackup

tmutil startbackup --auto — Start an automatic backup (can be deferred by the system).

sudo tmutil startbackup --auto

tmutil startbackup --block — Start a backup and wait until it finishes.

sudo tmutil startbackup --block

tmutil stopbackup — Stop a running backup.

sudo tmutil stopbackup

tmutil enable — Enable automatic Time Machine backups.

sudo tmutil enable

tmutil disable — Disable automatic Time Machine backups.

sudo tmutil disable

Status & Info

tmutil status — Show the current Time Machine backup status.

tmutil status

tmutil currentphase — Show the current phase of a running backup.

tmutil currentphase

tmutil listbackups — List all available backups (paths).

tmutil listbackups

tmutil latestbackup — Show the path of the most recent backup.

tmutil latestbackup

tmutil destinationinfo — Show information about backup destinations.

tmutil destinationinfo

tmutil machinedirectory — Show the machine-specific backup directory path.

tmutil machinedirectory

Snapshots

tmutil localsnapshot — Create a new local APFS snapshot.

sudo tmutil localsnapshot

tmutil listlocalsnapshots / — List all local snapshots on a volume.

tmutil listlocalsnapshots /

tmutil listlocalsnapshotdates — List dates of all local snapshots.

tmutil listlocalsnapshotdates

tmutil deletelocalsnapshots <date> — Delete a specific local snapshot by date.

sudo tmutil deletelocalsnapshots 2026-03-19-120000

tmutil thinlocalsnapshots / <bytes> — Delete local snapshots until the specified space is freed.

sudo tmutil thinlocalsnapshots / 10000000000

Exclude & Include

tmutil addexclusion <path> — Exclude a path from Time Machine backups (sticky, follows path).

sudo tmutil addexclusion ~/VMs

tmutil addexclusion -p <path> — Exclude a fixed path (does not follow if renamed).

sudo tmutil addexclusion -p /usr/local/var/mysql

tmutil removeexclusion <path> — Remove an exclusion.

sudo tmutil removeexclusion ~/VMs

tmutil isexcluded <path> — Check if a path is excluded from backups.

tmutil isexcluded ~/VMs

Destinations

tmutil setdestination <path> — Set the backup destination (replaces existing).

sudo tmutil setdestination /Volumes/BackupDrive

tmutil setdestination -a <path> — Add an additional backup destination.

sudo tmutil setdestination -a /Volumes/SecondBackup

tmutil removedestination <id> — Remove a backup destination by its ID.

sudo tmutil removedestination XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX

Restore & Delete

tmutil restore <src> <dest> — Restore a file or directory from a backup.

sudo tmutil restore '/Volumes/Backup/2026-03-19/Users/me/file.txt' ~/file.txt

tmutil delete <backup-path> — Delete a specific backup snapshot.

sudo tmutil delete /Volumes/Backup/Backups.backupdb/Mac/2026-03-01-120000

tmutil calculatedrift <backup-path> — Show the amount of data changed between backups.

tmutil calculatedrift /Volumes/Backup/Backups.backupdb/Mac

tmutil compare <backup1> <backup2> — Compare two backups or a backup with the current disk.

tmutil compare /Volumes/Backup/Backups.backupdb/Mac/2026-03-18 /Volumes/Backup/Backups.backupdb/Mac/2026-03-19

Conclusion

tmutil gives you full control over Time Machine – invaluable in scripts and on remote Macs. Be aware, though, that some subcommands are irreversible: delete and deletelocalsnapshots remove backups and snapshots permanently, and many operations require sudo. Always double-check the target and path before deleting anything or setting a new destination – a mistyped path can hit the wrong backup. For everyday use, startbackup, status and listbackups are usually all you need; keep the destructive commands for deliberate cleanup.

Further Reading

  • caffeinate – prevent the Mac from going to sleep
  • defaults – read and write macOS preferences (property lists)
  • diskutil – manage disks, volumes and partitions