Don't Sync All of All Mail

Is it possible only to sync the last few days of “All Mail”?. I have like 5GB in there and it is slowly syncing it all?

(Originally posted by Modelmat on GitHub.)

(Original post had 4 upvotes.)

Hey! Unfortunately with Gmail accounts, “All Mail” is necessary because all of your labels are actually subsets of All Mail. (So syncing only three days of All Mail would mean only three days of mail in your labels too.)

That said, there’s a configuration option I haven’t exposed yet that will let you limit sync to say “the last six months” or the last year of mail. The client won’t download it, won’t sync it, won’t index it for search, etc. Right now it doesn’t seem like it’s a huge feature request, but if we get more upvotes here I’ll prioritize getting the UI in place!

(Originally posted by bengotow on GitHub.)

1 Like


Related Issues:

I would like to ask to remove the requirement that the Gmail account must expose “All Mail” folder. In default iOS Mail client and in the client of macOS, if “All Mail” is exposed to IMAP, then all my mails will be downloaded twice, which is not acceptable. Hence, it will be very good if I can use Mailspring without needing to expose my “All Mail” folder to IMAP.

(Originally posted by ronisbr on GitHub.)

Hey! Thanks for filing this—unfortunately this was a pretty core design decision when we built the new sync engine. Supporting Gmail Labels properly (and showing them as real labels and not as folders like Apple Mail does) requires syncing the All Mail folder. (Mailspring avoids the “downloading twice” issue by /only/ scanning All Mail and ignoring the fake folders that Gmail creates for your labels.)

I’ll see if we can make it possible to link a Gmail account as a standard IMAP account in the future. That’d make it work just like (where you need to disable All Mail to avoid double-syncing your email, and labels appear as folders.)

(Originally posted by bengotow on GitHub.)

Thanks for the answer. I understand the problem and I think that it will work for my use case if I can connect to gmail as a standard IMAP. Is there any problem if I enable the “less-secure” option in Gmail and configure the account in Mailspring as a default IMAP? Would be that a workaround for this issue?

(Originally posted by ronisbr on GitHub.)

here is the issue I’m facing.

  • I have thousands of notification email with a label “notification”, these emails are skip-inbox when it is received, also I have excluded this folder from IMAP via Gmail settings.
  • I have 2000 emails limited for IMAP.

Now, since mailspring needs to enable “All Mail”, all the notifications are syncing to the “All mail” folder, and the worst thing is I have only 5 or 10 emails maximum showing up in the inbox (because of the 2000 IMAP limit set).

I was using mac mail earlier and resolved this issue by disabling the “All Mail” from Gmail IMAP setting.

It would be great if you could give me the option to disable “All mail” form Gmail IMAP settings.

(Originally posted by nixjobin on GitHub.)

How come we can’t just sync just the sub labels and not the ALL MAIL folder? You can in Gmail and also on the mobile applications. I am pretty sure we don’t need to sync the ALL MAIL Folder, but rather just the labels.

That would be really great. Feels like the only feature missing for completely replacing thunderbird!

1 Like

@bengotow Especially for IMAP accounts that support server search (i.e. Fastmail), I don’t think it makes sense to download all mail bodies. I have many gigabytes of emails with years of history. I actually don’t want everything on my laptop.

I wasn’t able to find the feature to limit the sync. Has it not yet been exposed?

I am surprised this isn’t a popular request? There should be a way to download just the INBOX, or choose which folders/labels to download. Nobody wants emails in ARCHIVE to be downloaded. It wastes bandwidth on 5 computers and makes the sync so slow Mailspring is unusable.