the personal weblog of paul burd, multimedia designer

Making Apple’s Mail work with IMAP

10.30.2006 – 11:36 am | by paul

Now that my host offers a better webmail client, I decided to switch my email account from POP over to IMAP, so I could access all my mail from anywhere. I was a very disappointed on how poorly Apple’s Mail application supported IMAP right out of the box.

If you’re using a .Mac address it works great, but it just didn’t work using a non .Mac account… at least not without some extra configuration.

THE PROBLEM

After setting up the account through my host, and setting up the IMAP account in Apple’s Mail, I found that items weren’t being synced as they should. Anything I did through the webmail client did show up in Mail, but things I did in Mail did NOT show up in the webmail client. For instance, I could send an email from Mail, and it would send, but it didn’t get written to the ‘Sent’ folder… it just disappears into oblivion without so much as an error message. I would call that a bug.

THE SOLUTION

When you first set up the account in Mail, you should see the folders that exist on the server, listed directly under the accounts inbox (see the updated content at the bottom of this post). For this example I’ve created an account called “my email”. Although Mail can see these folders, it has no idea what they are, so it refuses to write anything to them unless you actually drag and drop a message on to them. So, we need to educate Mail on what these folders are supposed to be used for. It’s very simple to do.

In the accounts list, select one of the folders listed under your new IMAP account. In this case I’m using the “Drafts” folder. Now, go to the “Mailbox” pull-down menu, and go down to “Use This Mailbox For” menu item, and select “Drafts”. When you do this, you’ll see that Drafts item you had selected in your account list jump from just under the account, down to the larger “Drafts” folder (the one with the folded paper icon). Now, Mail understands that this folder is meant for Drafts on your new account and will properly write draft emails to that folder, and in turn sync them to the server.

As you can see from the screen shot above, there are also items for “Sent”, “Trash”, and “Junk”. You’ll need to repeat the procedure listed above for those items as well. In my case, the junk mail folder on the server was called “Spam” by default, but that doesn’t matter. It can be mapped to my “Junk” item.

Once you remap these folders, everything should sync in both directions from Apple Mail, to webmail, and back again.

FOLDERS

If you’re like me, you don’t want to store everything in your Inbox. You’ll probably want to create custom folders to file your email. When I first tried to make a new remote folder through Mail, I got an error message saying that Mail could not write the folder to the server. But, I did find a way around this. First, quit Apple Mail. Then, log in through your webmail client, and create at least one custom folder. Now, open Apple Mail again. You should see the folder that you just created through webmail, and you should now be able to create new remote folders through Mail. I’m not exactly sure why this works, but I suspect it’s because Mail doesn’t know where to write the remote folder, without having at least one custom remote folder that already exists to act as a guide.

That’s it. You should now be able to use IMAP with Apple Mail.

UPDATE (11.1.06):

IMAP under @

A comment was left on this post yesterday by Paul Connolley, suggesting that I should also fill in the “IMAP Path Prefix” under the Advanced tab in Mail’s account preferences in order for my IMAP account to function properly. I double checked with my host, Media Temple, and they told me it was unnecessary. But, I tried Paul’s suggestion anyway, and upon doing so my folders associated with this account jumped from just below it’s inbox (as illustrated earlier in this post), to the bottom of Mail’s sidebar under a new folder with an “@” symbol (illustrated above). After looking around online last night, I discovered that this new display (under the @) is actually how it should be displaying. It should not be listed under the inbox, as it was earlier in this post. I told this to Media Temple, and they said I should go ahead and use “INBOX” as my Path Prefix, as Paul had suggested. note: “INBOX” works for my Media Temple account, and from my understanding is a fairly common Path Prefix, but you’ll want to double check with your host on what you should be using.

Thanks for the great tip, Paul.

note: this new screenshot is taken prior to remapping the folders, as described earlier, that’s why all the folders are still together. Even with using “INBOX” as your Path Prefix, you’ll want to follow the procedure listed above to educate mail on what these folders should be used for. After you remap the folders, you should only see your custom folders listed under the @, and not the standard folders, like Sent, Trash, Drafts, etc…

13 Responses to “Making Apple’s Mail work with IMAP”

  1. Non Stop Mac Says:

    Making Apple’s Mail work with IMAP…

    Paul Burd writes: “After setting up the account through my host, and setting up the IMAP account in Apple’s Mail, I found that items weren’t being synced as they should. Anything I did through the webmail client did show up……

  2. mungler Says:

    to be fair, how is Mail.app supposed to know which folders to use if you dont tell it first?

    i agree that it could be a little clearer that you need to do that, tho.

  3. jamie Says:

    Similar story here:
    Mail.app, IMAP, and Trash woes
    http://whatdoiknow.org/archives/002420.shtml

  4. Paul Connolley Says:

    You should also note that you are supposed to specify the IMAP folder as given by your email provider. Mail.app will not “function correctly” if you don’t specify the IMAP Path Prefix in your advanced settings. It is usually “INBOX”. You’ll find that will help. If you are still having problems with IMAP then it is probably a bad configuration on the server rather than something that you haven’t done.

    Trust me. I manage an IMAP server (de temps en temps). They can be troublesome.

  5. paul Says:

    Paul Connolley - Thanks for the tip about the Path Prefix. I contacted my host (media temple) about it, and they told me it wasn’t necessary to put it in. But, I did try adding INBOX as the prefix, and it did change things around. It moved my folders from under the icon in the inbox, to their own spot at the bottom of the sidebar under a new @ symbol box. After looking around on the internet last night, I discovered that having them display under their own @ box, is how it should be. I’m trying to get clarification from media temple about this. I’ll be updating the post as soon as I hear back from them. Thanks again.

  6. Walt Says:

    Paul and Paul: Thank you both for the excellent tips! I switched over one of my email accounts from POP to IMAP and it’s working perfectly.

  7. Quality Peoples » Blog Archive » Media Temple Webmail Says:

    [...] That’s great! So I set up Apple Mail to use IMAP, cuz that’s how I roll. I even got IMAP to save drafts and sent mail, courtesy of a tutorial from One Digital Life (thank Paul!). To make sure my drafts and sent mail were being synced with my web mail I logged on to Media Temple’s wicked “AJAX Webmail”. They give you 4 options: [...]

  8. ubi de feo Says:

    actually this tip saved my nerves.
    to make it clear.
    this issue only happens on Grid Servers, as I just switched and never had this kind of problem on MediaTemple (4 years uses).
    by the way this solves the issues, so…

    thank you

    ciao.ubi

  9. RyanC Says:

    I also noticed that until I put more than just 1 account into Mail, it just plain refused to show my complete folder list, with folders disappearing randomly, and all sorts of other troublesome behaviour!

  10. Nelson Says:

    Does anyone have any tips on archiving mail when using IMAP accounts? I have multiple IMAP’d email accounts, and like to save attachments and email records on my harddrive for reference purposes (we have many clients, and it’s a good insurance policy). I don’t want to be archiving emails within IMAP, since it’ll eat through my disk space too quickly; however, when I try to move an email from an IMAP folder to a folder on my local drive (aka: @Reference), I get an error message that it can not move the email. Any tips??

  11. Justin Says:

    Thanks for the great tip. This has been annoying me to no end, but now it is solved. This with the SSL’d goodness of the new grid server keeps me loving Media Temple.

  12. Johan Tegin Says:

    Thanks,
    Especially the imap path hint was great. My imap-supplier had hundreds of mailing lists that i couldn’t get rid of until i saw this page. Nice layout btw…

  13. Paul Connolley Says:

    Glad to have been of service.

    Any time.

Leave a Reply