IMAP with server deletion

Chris Coutinho chrisbcoutinho at
Fri Jul 5 06:30:12 PDT 2019

Offlineimap has a 'sync_deletes' flag that defaults to 'yes' in both your
local and remote repositories. You can elect to delete locally and keep
remote, or delete remotely and keep locally.

See the short comment in the offlineimap configuration file on github:

One point that is not clear is how to flag a message locally to be deleted
on the remote, without deleting the message locally. What you probably want
to do is delete your messages using the GMail UI using a browser.

Remember to make a backup!


On Fri, 5 Jul 2019 at 15:22, Sam Halliday <sam.halliday at> wrote:

> Hello all,
> I'm using emacs + notmuch + offlineimap + msmtp to manage my Gmail.
> My gmail account is starting to get so big that an offline sync is time
> consuming.
> I'd like to delete messages on the server, but keep them locally. Is
> that possible with IMAP?
> There is one complicating factor that stops me from being able to use
> fetch-only POP3: I'd like to keep files on the server if they have the
> +flagged tag, which is equivalent to "starred" in the Gmail interface.
> Has anybody got a setup similar to this?
> --
> Best regards,
> Sam
> _______________________________________________
> notmuch mailing list
> notmuch at
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the notmuch mailing list