# Install imap-backup with Homebrew

Backup GMail (or other IMAP) accounts to disk. Version 16.6.0 via Homebrew; verified 2026-06-06.

## Install

```sh
sudo av install brew:imap-backup
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install imap-backup
```

  Evidence: local Homebrew formula metadata

## Package facts

- **Package key:** brew:imap-backup
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/imap-backup>
- **Version:** 16.6.0
- **Source summary:** Backup GMail (or other IMAP) accounts to disk
- **Homepage:** <https://github.com/joeyates/imap-backup>
- **Repository:** <https://github.com/joeyates/imap-backup>
- **Upstream docs:** <https://github.com/joeyates/imap-backup#readme>
- **License:** MIT
- **Source archive:** <https://github.com/joeyates/imap-backup/archive/refs/tags/v16.6.0.tar.gz>
- **Last updated:** 2026-06-06T17:04:39Z
- **Generated:** 2026-07-08T18:08:21+00:00

## Executables

- imap-backup (cli)
- imap-backup (alias)

## Dependencies

- ruby

## Uses from macOS

- libffi

## Install behavior

- Post-install hook: not defined
- Bottle: available on arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## Freshness

- Page generated: 2026-07-08
- Package-manager version: 16.6.0
- Package-manager updated: 2026-06-06
- Local data: ok
- Upstream repository: https://github.com/joeyates/imap-backup
- Upstream latest detected: v16.6.0 (current)
## Project history and usage

imap-backup is a Ruby command-line tool for backing up and migrating IMAP email accounts to local disk. It targets Gmail and other IMAP services, storing messages in mboxrd files with companion metadata.

### Project history

The RubyGems version history shows `imap-backup` beginning with 0.0.1 in 2012 and reaching 1.0.0 in early 2013. The project's developer documentation states design goals of secure local configuration, restartable operation, and independence from a mail client or MTA.

The tool has grown from basic account backup into a broader IMAP maintenance utility. Recent changelog entries document download strategies, Thunderbird export improvements, configuration-free single-account backups, container images, a consolidated `copy` command replacing older migration and mirror flows, account locking, metadata migrations, and internationalization.

### Adoption history

imap-backup is distributed as a RubyGem and as a Homebrew formula. RubyGems download counts are much higher than Homebrew installs, which fits a Ruby CLI whose main package channel is the gem ecosystem, while Homebrew gives Mac and Linux users a convenient binary-package entry point.

The package's adoption comes from a durable personal-infrastructure problem: IMAP accounts need local, restartable, scriptable backups without coupling the archive to a desktop mail client. Its docs also cover migration and restore operations, so the tool is used for both preservation and moving mail between providers.

### How it is used

`imap-backup setup` creates configuration, and `imap-backup backup` copies messages for configured accounts to disk. The backup command is incremental and interruptible, and stores email in mboxrd files with IMAP metadata containing offsets and message lengths.

The config documentation records the default path as `~/.imap-backup/config.json` and warns that usernames and passwords are stored in plain text there, with permissions set on Unix-like systems. Other commands include restore, copy, and single-account backup flows, with performance settings for delayed metadata writes and multi-fetch size.

### Why package nerds care

imap-backup is package-nerd significant because it turns email portability into a boring CLI workflow. It also demonstrates the tradeoffs of local-first backup tools: plain JSON configuration, mboxrd serialization, metadata version migrations, locking, and careful restart behavior matter more than a large service backend.

### Timeline

- 2012: imap-backup 0.0.1 was published to RubyGems.
- 2013: imap-backup 1.0.0 was published to RubyGems.
- 2022: The changelog records backup flags, mirror mode, stats, and provider-specific backup fixes in the 6.x and 7.x lines.
- 2023: Version 14.0.0 added configuration-free single-account backups, and 14.3.0 added container images.
- 2024: Version 16.0.0 added the `copy` command and deprecated older migrate/mirror commands.
- 2026: The 16.x and 17.0.0.rc0 lines added localization, account locking, metadata migration, and mboxrd serialization fixes.

### Related projects

- imap-backup is related to IMAP synchronization and archival tools such as isync/mbsync and offline mail workflows, but its docs emphasize local mboxrd backups plus restore/copy operations rather than maintaining a live Maildir mirror.

### Sources

- <https://formulae.brew.sh/api/formula/imap-backup.json>
- <https://github.com/joeyates/imap-backup>
- <https://raw.githubusercontent.com/joeyates/imap-backup/main/CHANGELOG.md>
- <https://raw.githubusercontent.com/joeyates/imap-backup/main/docs/commands/backup.md>
- <https://raw.githubusercontent.com/joeyates/imap-backup/main/docs/files/config.md>
- <https://rubygems.org/api/v1/gems/imap-backup.json>
- <https://rubygems.org/api/v1/versions/imap-backup.json>


## Security Notes

broad file, network, media, or database tool signal.

- **Geiger risk:** blue / medium
- broad file, network, media, or database tool signal


## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Configuration files

- Unix: ~/.imap-backup/config.json

## Credential files

- Unix: ~/.imap-backup/config.json
## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** imap-backup
- **Version Scheme:** 0
- **Revision:** 0
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** stable


## Related links

- [Source-control packages](https://www.automicvault.com/pkg/source-control-tools/) - Belongs to a source-control command family.
- [Secret-risk packages](https://www.automicvault.com/pkg/secret-risk-packages/) - Has protected-tool coverage, approval-gate, or non-low Geiger security signals.
- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Networking and protocol packages](https://www.automicvault.com/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [ruby](https://www.automicvault.com/pkg/brew/ruby/) - Runtime dependency declared by Homebrew.
- [imapsync](https://www.automicvault.com/pkg/brew/imapsync/) - Shares av.db curated category or tags: cli, email, email-backup, email-migration, imap.
- [gmailctl](https://www.automicvault.com/pkg/brew/gmailctl/) - Shares av.db curated category or tags: cli, email, gmail, productivity.
- [gyb](https://www.automicvault.com/pkg/brew/gyb/) - Shares av.db curated category or tags: cli, email, gmail, productivity.
- [himalaya](https://www.automicvault.com/pkg/brew/himalaya/) - Shares av.db curated category or tags: cli, email, imap, productivity.
- [imapfilter](https://www.automicvault.com/pkg/brew/imapfilter/) - Shares av.db curated category or tags: cli, email, imap, productivity.
- [mailcheck](https://www.automicvault.com/pkg/brew/mailcheck/) - Shares av.db curated category or tags: cli, email, imap, productivity.
- [meli](https://www.automicvault.com/pkg/brew/meli/) - Shares av.db curated category or tags: cli, email, imap, productivity.
- [neomutt](https://www.automicvault.com/pkg/brew/neomutt/) - Shares av.db curated category or tags: cli, email, imap, productivity.

## Combined YAML source

View the package source record on GitHub. [combined/imap-backup.yml](https://github.com/automic-vault/db/blob/main/combined/imap-backup.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated configuration and credential file locations
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- cross-ecosystem install command graph
