Want to highlight a helpful answer? Upvote!

Did someone help you, or did an answer or User Tip resolve your issue? Upvote by selecting the upvote arrow. Your feedback helps others! Learn more about when to upvote >

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Migrating Mail to a new Mac

I see a lot of people asking how to do this, so I’ll share my recent experience. If you ask how to transfer POP Mail accounts between Macs, you’ll typically be told to just use Apple’s Migration Assistant. Indeed, if you want your new Mac up and running quickly, do this! If however, your Mac has accumulated years of old data and you don’t like the idea of migrating a ton of redundant (and potentially corrupt) Library files, you may want to do a clean install. Apple, unfortunately, doesn’t imagine that users want to do this, so its documentation on manual migration are scant at best. (In your search, you may also encounter a number of faithful Apple forum regulars who will tell you that clean installs are never needed and that in all their years they have never encountered a corrupt preference file or erratic behaviour on their Mac. Just smile and congratulate them on their good fortune.)


If you go to Google you’ll find that most articles tell you it’s a simple matter of copying the ~/Library/Mail folder and one or two preference files. Unfortunately, this old method hasn’t worked for some years. Mail account information is now stored within ~/Library/Accounts, and transferring it isn’t as simple as it should be.


The most helpful answer I found was this one by apple_mikey in the Manual Mail Migration discussion.


However, this comment is over two years old now, and I still had some problems trying to migrate Mail between El Capitan (10.11) and High Sierra (10.13).


First problem: The database files within Library/Accounts don’t appear to be compatible. At the very least, the names have changed, from ‘Accounts3.sqlite’ to ‘Accounts4.sqlite’. If you simply overwrite the Accounts folder or otherwise delete the ‘Accounts4.sqlite’ files, High Sierra just creates new ones, and the old accounts aren’t recognised. So I tried simply editing the file name, replacing the ‘3’ with a ‘4’. After a restart, the old accounts were all there!


Second problem: None of my email accounts would recognise the correct passwords. I knew I was using the correct passwords, but no matter how many different ways I tried to enter them, it kept saying ‘Unable to verify account name or password’.


This issue is discussed in some detail in the article, How to solve the Apple mail Unable to verify account name or password issue. I had partial success with the technique described there. Sometimes it worked, sometimes it didn’t. This wasn’t the solid, predictable feel I wanted from my clean install!


On top of this, none of the mailboxes under ‘On My Mac’ (all the folders used by my Mail rules to organise mail) had migrated across.


In frustration I finally gave up, and decided to just recreate every account on the new Mac, export each of the mailboxes from the old Mac, and import them into Mail on the new Mac. This is a tedious process, but it mostly works. It goes something like this:


  1. In Mail on the old Mac, select the corresponding In and Sent mailboxes for each account and choose ‘Export Mailbox’ from the Mailbox menu.
  2. Rename the mailbox files in the Finder to distinguish them from other accounts' mailboxes.
  3. Transfer these files to your new Mac. (I transferred all files via a Thunderbolt cable. Lightning fast.)
  4. In Mail on the new Mac, set up each of your accounts.
  5. Depending on your POP settings, Mail may start downloading a week’s worth of previously downloaded messages and marking them unread, which probably isn’t what you want. You can delete these messages from the server first (which is what I did), or delete them after they have downloaded and before you import.
  6. Choose 'Import Mailboxes' from the File menu and select the mailbox files you previously exported for each account.
  7. You now want to move the imported messages to each account’s Inbox and Sent mailboxes. By default, Mail does not display a Sent mailbox for an account until you have actually sent something. This makes for a clean typically-Apple interface, but isn’t helpful when you need to drag files to an invisible mailbox! To address this, I sent an email to nobody@mydomain from each account, which created the corresponding Sent mailboxes.
  8. You’ll find all your imported mailboxes in a folder labelled ‘Import’ within ‘On My Mac’ in the sidebar. Click on each mailbox, select all the messages (I use Mail’s ‘classic layout’ for this), and drag them to the corresponding account’s Inbox or Sent mailbox.
  9. Check that all the Import folders/mailboxes are now empty before deleting them.
  10. Import any other ‘On My Mac’ mailboxes that you had on your old system, and move them out of the Import folder, so they are directly within ‘On My Mac’.


I say this ‘mostly’ worked, because upon import I received the warning that ‘Some messages could not be imported’. Sigh. You can always compare the number of messages between your old Mac and new to see what the damage is.


I hope someone finds this helpful.


It would be great if Apple simplified this by providing a way to export accounts, rather than just mailboxes. Imagine being able to export an email account, complete with all settings (minus passwords for security), and simply imported the account on the new Mac to resurrect all the associated mailboxes and messages. I’m sure Apple could make this a beautifully simple experience if they put their clever minds to it.

iMac (Retina 5K, 27-inch, 2017), macOS High Sierra (10.13.2)

Posted on Jan 18, 2018 4:01 PM

Reply
Question marked as Best reply

Posted on Jan 20, 2018 7:43 PM

Two tips worth adding:

  1. If you have nested folders within ‘On My Mac’, selecting the parent folder and choosing ‘Export Mailbox’ does not work as expected. You need to expand the folders at every level and select them all before exporting. (Once you do that, your folder structure is nicely recreated in the Finder along with all your messages.)
  2. Mail’s import feature chokes on large mailboxes, no two ways about it. One of my archived mailboxes had over 27,000 messages, and mail took many hours trying to import it. Since the import progress bar gives no useful information whatsoever, it can appear as though the process has completely stalled, but if you click on the partially imported mailbox in Mail, you can see the number of emails slowly increasing. I tried it twice, and both times the mailbox reached precisely 15,339 messages before the process ended and I got the 'Some messages could not be imported’ warning. The workaround, shared here by jmac3, is to export mailboxes in smaller chunks. A clever way of doing this is to define Smart Mailboxes based on time periods, e.g. 1/1/2015–31/12/2017, 1/1/2012–31/12/2014, etc.
2 replies
Question marked as Best reply

Jan 20, 2018 7:43 PM in response to Kalsta

Two tips worth adding:

  1. If you have nested folders within ‘On My Mac’, selecting the parent folder and choosing ‘Export Mailbox’ does not work as expected. You need to expand the folders at every level and select them all before exporting. (Once you do that, your folder structure is nicely recreated in the Finder along with all your messages.)
  2. Mail’s import feature chokes on large mailboxes, no two ways about it. One of my archived mailboxes had over 27,000 messages, and mail took many hours trying to import it. Since the import progress bar gives no useful information whatsoever, it can appear as though the process has completely stalled, but if you click on the partially imported mailbox in Mail, you can see the number of emails slowly increasing. I tried it twice, and both times the mailbox reached precisely 15,339 messages before the process ended and I got the 'Some messages could not be imported’ warning. The workaround, shared here by jmac3, is to export mailboxes in smaller chunks. A clever way of doing this is to define Smart Mailboxes based on time periods, e.g. 1/1/2015–31/12/2017, 1/1/2012–31/12/2014, etc.

Migrating Mail to a new Mac

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.