Back to News

Introducing ImapGoose

@WhyNotHugo
October 16, 2025 at 12:28 AM
Surprise (20%)
neutral

Key Takeaways

  • ImapGoose is a daemon designed for continuous, near real-time synchronization between local maildirs and an IMAP server.
  • It heavily relies on modern IMAP extensions (CONDSTORE, QRESYNC, NOTIFY) standardized between 2005 and 2009 for efficiency.
  • The use of CONDSTORE and HIGHESTMODSEQ allows for highly efficient incremental synchronization, avoiding the download of entire message lists.
  • The NOTIFY extension enables immediate notification of server changes without constant polling, supporting multiple mailboxes per connection.
  • The program maintains a status database to track mailbox states and uses an exponential back-off strategy for automatic reconnection after network interruptions.

ImapGoose is a small, optimized program engineered to function as a daemon, continuously monitoring both the IMAP server and the local filesystem to ensure immediate synchronization of email changes. Its design prioritizes efficiency, minimizing network traffic by relying on several modern IMAP extensions standardized between 2005 and 2009. Specifically, it uses CONDSTORE to request only new changes since the last known state (HIGHESTMODSEQ) and QRESYNC to receive lists of deleted messages. Furthermore, the NOTIFY extension allows ImapGoose to maintain an open connection and receive immediate alerts about changes, surpassing the limitations of the older IDLE extension by supporting multiple mailboxes per connection. The operational flow involves an initial listing, followed by monitoring via server notifications and local filesystem watchers, and then performing sync tasks based on the status database which maps server UIDs to local filenames. Upon disconnection, ImapGoose attempts automatic reconnection using an exponential back-off strategy.

Related Articles