How to Make Apple Mail.app Get Along With Gmail
Apple Mail.app is the greatest email client and Gmail is the greatest email system. However, they don’t get along well easily. I grappled with the configuration for a while and now I’m pretty happy with it. My philosophy is to make Apple Mail.app a beautiful and thin client for Gmail, instead of replacing Gmail’s web interface completely. Here I’m sharing what I have done to configure Mail.app 4 to work nicely with Gmail. I hope it helps.
Step 1. Enable IMAP in your GMail account.
Step 2. Remove “fat” labels from IMAP. They may choke Mail.app or even block IMAP access to Gmail.
Gmail labels are considered as mailboxes in IMAP. If a label applies to too many emails, it may slow down the client significantly. Things may get worse when Mail.app downloads too many emails – Gmail will block IMAP access to your account for 24 hours. You will get the “Account exceeded bandwidth limits” failure when you use Mail.app to get emails. So you definitely want to remove those “fat” labels from IMAP. Here is how.
First, enable “Advanced IMAP Controls” in Gmail labs. To do it, go to “Settings” -> “Labs”, find “Advanced IMAP Controls” and enable it.
Then go to “Settings” -> “Labels”. You will see each label now has a checkbox – “Show in IMAP”. Unchecking that checkbox will remove that label from IMAP. “All Mail” is the first one you want to remove. Also do not show “Spam”, “Trash” and “[GMail]/Spam” . If you have custom labels that are not very important but have a lot of emails, do not show them in IMAP as well.
By doing this, obviously you won’t have access to all of your emails, but you need to think about if that’s really a problem for you. It is never a big problem for myself. I extensively use filters in Gmail to label emails automatically. I don’t have to label them manually in Apple Mail.app. For emails that I have processed, I archive them and I usually don’t need to access them. So it doesn’t matter even if they are not accessible in Apple Mail.app.
Step 3. Configure Apple Mail 4 to access Gmail through IMAP.
Step 4. Do not save draft on Gmail, since it causes a very weird behavior.
Saving draft on Gmail servers causes a very weird behavior. Every time when Apple Mail.app automatically saves an unfinished draft, the draft is saved as a separate email in that thread and then being marked as deleted. So if you go to Gmail’s web interface, you will find that thread has *** messages in Trash.
To not save draft on Gmail, go to “Preference” -> “Account” -> “Mailbox Behaviors” and uncheck “Store draft messages on the server”. The risk of doing this is that drafts composed in Apple Mail.app won’t show up in Gmail’s draft box.
Step 5. Archive messages on Gmail even if delete from Apple Mail.app.
When you remove a message from the Apple Mail.app inbox, you may want it to be archived instead of being actually deleted. To do it, go to “Preference” -> “Account” -> “Mailbox Behaviors” and uncheck “Move deleted messages to the Trash mailbox” and check “Store deleted messages on the server”.
If you actually want to delete a message, you can drag it to the “[GMail]/Trash” mailbox. I usually do not do it, because I have filters set up on Gmail to label emails. I use labels to clean my Gmails account regularly.
Step 6. Disable spam filtering in Apple Mail.app.
Gmail’s spam filtering works great, so you don’t actually need local spam filtering. It sometimes slows down the machine. It’s your choice. To disable it, go to “Preference” -> “Junk Mail” and uncheck “Enable junk mail filtering”.
Step 7. Get Gmail-like thread grouping.
I like Gmail’s thread grouping, i.e. grouping all emails in a thread all together, including received emails and sent emails. Apple Mail.app can also do that. First, go to “View” and check “Organize by Thread”. To also put sent emails in thread groups, you need to always Bcc to yourself – go to “Preference” -> “Composing” and check “Automatically Bcc: myself”. Then set up a rule to mark those emails as “Read” automatically. Go to “Preference” -> “Rules” -> “Add Rule” and you will know what to do.
Last, go to “Preference” -> “Accounts” -> “Mailbox Behaviors” and uncheck “Store sent message on the server”. If you don’t do it, sent emails will be labeled with a weird label – “Send Message”.
Step 8. Install the greatest email notifier – Herald.
Herald is the best email notifier on Mac. I especially like its slick looking, in-notification pre-review and short-cut action buttons. Go to its website, download and install it as an Apple Mail.app plugin.
If you have filter on Gmail to label emails automatically, Herald may pop up duplicated notifications of the same email, this is again because Gmail labels are considered as mailboxes in IMAP. If an email is automatically labeled with one label, it appears in both the inbox and the mailbox for that label. So Herald will see them as two different emails. There is a way to fix, since Herald allows you to specify which mailboxes to check for new emails. Just go to “Preference” ->”Herald” -> “Mailboxes” and uncheck all mail boxes except inboxes.
Now you’re all set. Enjoy. :-)
I like step 8 the best :)
Thanks! Finally, some clear explanations of so many issues related to using Gmail with Apple Mail.
One feature I feel is still not handled easily is deleting versus archiving a message. As you say, you can delete a message by moving it to the [Gmail]/Trash mailbox. However, if you are using multiple Gmail accounts, you have to be careful to move the message to the correct [Gmail]/Trash, which is very annoying. If you move it to the wrong [Gmail]/Trash, it ends up only being archived in the original account. Also, it would help to have a nice keyboard shortcut or menu item to do this, since I delete lots of emails.
To have the “[Gmail]/” prefix not show for all the labels in Gmail online you need to make a new label called “[Gmail]/” so that a nested label is created and all your labels will be under [Gmail]/.
[...] Changing some of the local settings on Mail.app makes Gmail play a bit nicer. [...]
I was wondering if we could discuss the article further. First of all everything appears to have worked and now apple mail mimics to a certain extend, how gmail functions. That being said was wondering how you handle archiving old email etc. I need to be able to only deal with the most recent 3-6 months of mail but for anything older unless I star it I probably don’t need it in my computer. How do you handle archiving? and other maintenance tasks. At some point even mail.app gets database sizes that are too big to operate efficiently. Either this thread for future researchers or you can PM me. Gmail and IMAP can be qwirky
For Step 7. Get Gmail-like thread grouping:
There is a much easier way to display your sent messages in conversation view than bcc-ing yourself. Under Mail –> Preferences –> Viewing, check “include related messages”
I don’t have to activate Advanced IMAP in Gmail to be able to check labels. Maybe that setting has been made part of the regular feature set by now.KK
Many thanks for the useful info.
Really-really helpful to make my Mail.apps slimmer and faster.
Info only:
If we also use Blackberry for receiving emails from GMail, hiding the “All Mail label” will make the Blackberry cannot retrieve any email from GMail again.