April 13, 2015 Aaron Carpenter

Copying Mail by IMAP To Google Apps (Or another server)

If you just want the goodies step by step scroll to the bottom of this post.

SO.  There I was, migrating mail from one legacy server to Google Apps.  I’m familiar with IMAP and POP3, but I wasn’t getting very far using Office 365 and Google’s User Sync tool to get the mail imported.  The furthest I could get was getting the labels to add programmatically through the sync tool.  However, no mail would transfer with it.

After some experimenting, I found a solution at the time of this post that is confirmed to work that I hope other administrators might find helpful.

  1. Download Mozilla’s Thunderbird for mac or windows(https://www.mozilla.org/en-US/thunderbird/), and add this extension to copy folders (https://addons.mozilla.org/en-us/thunderbird/addon/copy-folder/).  You will need to restart Thunderbird once the add-on is installed.  At the time of this post, the add-on gives you the install instructions (but you can find it quite easily in the settings > add-on > settings > install from file).
  2. Next, add both accounts to Thunderbird (The source server and the Google Apps Account).   Mozilla’s Thunderbird app does a pretty good job of auto-detecting your server settings, but you may need to log into cPanel to get the source server mail setup settings if you’ve already flipped the MX records to point to Google Apps so that the users are already catching their mail there.
  3. Once both accounts are set up, simply select all of your folders on the source account and copy them to the Google Apps account (Or your destination server).  In the case of Google Apps Migrations make sure you copy the folders / labels to the ROOT of the account (i.e. choose the name of the account so that all of the folders copy over as labels.

Voila, that should be it.

If you run into more difficulty, I’d suggest contacting Google’s Apps for Work support team for assistance (https://support.google.com/a/table/3247295?hl=en).  They were very helpful and responsive to my migration, even if we had to figure a solution out for ourselves, I’m quite sure that’s only due to an anecdotal technical issue to the Outlook installation we were initially using.

Good luck!

About the Author

Aaron Carpenter My name is Aaron Carpenter and I've been building web applications since 2002. Helping shape internet experiences for people to best match what their users are looking for, and creating web applications that become online tools to help manage businesses is what I love to do most.

View all posts by Aaron Carpenter


Building websites and web applications since 2010.