Search Support

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Learn More

IMAP folders not syncing as expected

  • 8 replies
  • 0 have this problem
  • 4 views
  • Last reply by Mark Lang

more options

I am still having trouble understanding IMAP folder syncing in Thunderbird. On a previous post (https://support.mozilla.org/en-US/questions/1099520), I talked about trying to get six different email accounts set up under IMAP to download messages to Thunderbird so I can back them up locally using a program called MailStore Home. That is mostly working, but two questions have emerged:

I was told that, when set to sync for the last 30 days, for example, and download, Thunderbird would download the last 30 days of messages. However, on day 31 it would download the new messages, but leave ones previously downloaded in the local folder. That is what I wanted. I set up my accounts this way. However, when I tried to back them up locally, the messages older than 30 days that had been downloaded previously were not found. They showed in the list of emails, but MailStore Home did not find them. My one account that had no new emails in the last 30 days showed ones downloaded previously, but the folder in Thunderbird was empty. I had to change to sync the last 90 days, and let Thunderbird then redownload the missing emails. After that, MailStore Home found them and archived them. I just want to clarify that Thunderbird, perhaps after I compact files, will actually remove previously downloaded emails that are older than the sync setting. I can work with this. I just need to remember to do my local archiving more often than the sync window.

My other question is, is there a way to force Thunderbird to manually sync the different email folders. This seems to happen periodically, but I cannot predict when. I could not find a plugin or command to do that. My intent is to just make sure that all my accounts are fully synced and downloaded before I run a local archive.

Any advice is appreciated. Thanks.

I am still having trouble understanding IMAP folder syncing in Thunderbird. On a previous post (https://support.mozilla.org/en-US/questions/1099520), I talked about trying to get six different email accounts set up under IMAP to download messages to Thunderbird so I can back them up locally using a program called MailStore Home. That is mostly working, but two questions have emerged: I was told that, when set to sync for the last 30 days, for example, and download, Thunderbird would download the last 30 days of messages. However, on day 31 it would download the new messages, but leave ones previously downloaded in the local folder. That is what I wanted. I set up my accounts this way. However, when I tried to back them up locally, the messages older than 30 days that had been downloaded previously were not found. They showed in the list of emails, but MailStore Home did not find them. My one account that had no new emails in the last 30 days showed ones downloaded previously, but the folder in Thunderbird was empty. I had to change to sync the last 90 days, and let Thunderbird then redownload the missing emails. After that, MailStore Home found them and archived them. I just want to clarify that Thunderbird, perhaps after I compact files, will actually remove previously downloaded emails that are older than the sync setting. I can work with this. I just need to remember to do my local archiving more often than the sync window. My other question is, is there a way to force Thunderbird to manually sync the different email folders. This seems to happen periodically, but I cannot predict when. I could not find a plugin or command to do that. My intent is to just make sure that all my accounts are fully synced and downloaded before I run a local archive. Any advice is appreciated. Thanks.

All Replies (8)

more options

The way IMAP synchronisation works is described here: https://support.mozilla.org/en-US/kb/imap-synchronization#w_synchronization Personally I think of it as two folders always keeping 'in step'. If I have stuff in a TBird folder that is 'subscribed' to a corresponding folder on my email provider's server, then whatever is in my TBird folder is in the server folder and vice versa. If I delete a message from one it disappears from the other; if I add a message to one it appears in the other. If I want messages in a folder on the server that I don't want in TBird, then I set TBird not to subscribe to that folder; and if I want to keep messages in TBird and not to have them on the server, I move them to the TBird 'local folders' account. So far as I'm aware every email client does the same because that's simply how the IMAP protocol works -- it's not specifically a Thunderbird thing. Hence I don't understand your queries about setting TBird to sync and download for a certain period -- 30 days or whatever. In my version of TBird there is no such functionality: a TBird folder is either subscribed to the server or it isn't, and if it is, it mirrors exactly what is in the server folder, however far back in time. Are you sure that the functionality you are asking about isn't in fact part of your Mail Store Home program, rather than part of Thunderbird? I don't know what that program is or how it works, do they have a support forum where you can ask your question as well?

more options

Thanks for your reply. My issue arises because, for many years, I simply downloaded my emails using POP, deleted ones I did not want, and archived using MailStore Home., I use the archive because years ago I found that Thunderbird becomes unstable when the mail folders get very large. The local folder and archive have been my master.

I recently switched all the accounts to IMAP so they will sync on my smartphone. I am trying to retain my local master, while taking advantage of the server to sync. However, 5 of my accounts are hosted on Google, which server keeps essentially all past emails up to extremely large stores. If I sync and download my Thunderbird accounts with the Google servers without time limit, it will try to download all those years old emails, including ones I deleted previously with POP, and I will have unmanageably large Thunderbird folders again.

I first had issues with the Google alternate folders that are really labels, such as allmail. They showed up the first time I synced my new IMAP accounts. However, I found that Thunderbird allows me to not sync or download them, in fact to control sync and download separately. Now, I am just trying to keep key folders including Inbox, Sent Mail, and Drafts synced, while also keeping the last few months emails downloaded into my local folders so the most recent are there when I go offline and they stay there long enough for me to archive them with MailStore Home every month or so.

With Thunderbird set to sync only the last 90 days, I am probably at a point that will do what I want. As long as I have 90 days of emails in the local IMAP folders, and I run the local archive at least once in that window, I should be OK. I was going to delete the emails older than 90 days after I have archived from the local folders, also, so my local folders don't become too large. That may not be needed if Thunderbird removes them. Kudos to Thunderbird for having this flexibility.

As I noted, I was just surprised that Thunderbird seems to literally sync the 90 day window to the point of removing emails older than 90 days that were previously downloaded. I had thought it would just leave downloaded emails there once they are downloaded. I also have not found a way to manually force all the accounts to sync so I can run that right before I do a local archive operation. I do run the Xpunge plugin to empty the trash and compact folders on every account so I have clean folders to archive. I try to make sure I have not done a lot of work such as deleting emails in a while so they are synced. I notice that the compact files operation will not run unless I am online, so Thunderbird must be checking with the server. Also, occasionally I get an error message when I run Xpunge that "the operation cannot be completed because the folder is busy." I have learned that means one of the accounts is in the middle of syncing, so I just wait a while and run Xpunge again.

I know I could just copy files I want to save locally and archive into local folders, which are not subject to syncing. However, with several folders in each of six email accounts to save, that would be a lengthy process I hope to avoid. Perhaps there is a better way to sync accounts but also have a master saved locally. Any advice is appreciated, especially if there is a way to manually sync accounts or know when they were last synced. Thanks.

more options

basically your trying to turn IMAP onto POP. Regardless of what you assume, what occurs will be what is set out in the relevant RFC. in this case primarily rfc3501

First you instability issues. Are they 10 years old? Thunderbird has no stability issues when mail is stored in folders of less that 4Gb nd nevr did in my experience.

If you want Google mails synced from a date set it in a gmail. They do have an option to only sync mail after a certain date. Usually the date you enable IMAP

more options

Matt, I appreciate your response. My situation is probably different than many. I believe I am trying to get the functionality of IMAP, but also downloading messages so I can access them locally offline and also keep a full archive locally. I am of moderate technical ability, so I may ask some basic questions as I try to figure out a new thing for me such as IMAP. I appreciate having this forum and people like you to help. It is a key reason why I have stayed with Thunderbird for many years. From what you said, I also need to study the Google options it appears.

The instabilities I experienced in Thunderbird do go back many years. I don't recall exactly. However, after I found MailStore Home, that is better for archiving for me anyway because it has deduplication on attachments (I often send the same attachments to several different people) and also it breaks up the files where it stores archives into smaller ones that are easier to backup and manage. It is a simplified free version of a very powerful commercial backup package, which is why it has some nice features not often found with free programs. I am probably pushing its limits. However, the MailStore folks only offer the free home version and complex commercial versions; there are no kind of semipro versions at lower cost.

For amanchesterman, if you look under the tools > account settings>your account>synchronization and storage you will see the options to download only emails for the last n days, which can be specified. Which folders get downloaded is accessible under the Advanced tab at the top of that section. You will find the option to subscribe only to certain folders under File>Subscribe. There is quite a bit of flexibility once you figure out all these settings.

I am still experimenting a bit. The one thing I have not found to this point is a way to manually sync folders and download. Thanks again to everyone for the support.

more options

Basically you need to do pop for your backup store and IMAP for your day to day.

I would suggest you create a new Thunderbird profile that has the accounts in POP form and only use it say once a month to download mail for archival. your day to day will delete what needs to be deleted.

Conversely it might be you need a new profile for IMP and revert your existing to POP. it depends on what you are doing really.

Multiple profile management get easy is you use this add-on. https://addons.mozilla.org/en-US/thunderbird/addon/profileswitcher/

It puts handy options in the file menu to switch between profiles and access the profile manager. Much better that command line switches.

more options

Matt, Thanks so much. That is a very interesting idea. I will try that when I have a chance and report back. Can you have Thunderbird running on two profiles at the same time? In other words, would I need to close the IMAP profile when I was downloading with the POP profile for backups? I assume the servers will respond as if the two different profiles were coming from different devices. Thanks again.

more options

I would suggest using them one at a time. There is a hack to make both open at once, using a command line switch. But I would not recommend it for day to day usage. as it messes with opening URLs in email.

more options

Matt, I was about to create the alternate Thunderbird profile for POP downloads. Then I remembered that POP will only download the Inbox. I will miss any Sent Messages in particular, along with drafts and templates that I want to save. Unless there is a way for POP to access those other folders, I guess I will stick with backing up from the IMAP folders. I just ran my second backup from the IMAP folders, and it seems to have worked fine. I will try to do backups more often, once a week or so, while retaining downloaded emails in the folders for 90 days or more. That way if some are missing for some reason when I back up they will be picked up the next time I back up.

I just ran MailStore Home on the selected IMAP folders. I then perused the archive. I see a list of emails added starting where I did the last backup and incrementing regularly up to today's date. So I seem to have gotten all the emails I want to save.