Apple Mail unable to send or receive – stuck syncing a Gmail or other IMAP account

17th Dec 2010

If Apple Mail is stuck synchronising changes to a Gmail or other IMAP server (especially if you’ve just sent a 40MB attachment to someone) it probably has a list of tasks to perform next time it’s ‘online’. This list is called the offline cache.

To remove the offline cache you’ll need to find it, hidden inside Apple Mail’s storage folders and invisible for good measure. Luckily finding the folder is quite simple:

  1. Quit Mail
  2. Click on the Finder icon in the dock
  3. Go to the Go menu > Utilities > open Terminal
  4. Assuming your email account is [email protected], your IMAP folder will be called [email protected] and inside this folder is the invisible offline cache called “.OfflineCache”.
  5. Type the following command into Terminal : open [email protected]/.OfflineCache then push return
  6. The .OfflineCache folder should open, move everything inside it into the trash
  7. Open Mail

The tilde character ~ tells the computer to go to your user’s home folder (so you don’t delete the offline cache of another user, prompting arguments!).