Gmail – How do the [imap]/Drafts, [imap]/Sent and [imap]/Trash folders work

gmailgmail-labelsimap

When you enable IMAP access in Gmail the [imap]/Drafts, [imap]/Sent and [imap]/Trash labels are created.

How do these labels function given that each IMAP client can potentially implement their local <–> server folder mapping in different ways?

Taking these label/folder names at face value I'd assume that they map to the client's Drafts, Sent and Trash folders respectively. But I haven't found this to be the case at all as Thunderbird handles folder mapping one way, the iPhone 4 IMAP client another, Outlook yet another and so on.

At the end of the day I want what every IMAP user wants which is their sent messages to show up in whatever the server's sent folder is called, same for trash and drafts.

Best Answer

You need to set up your IMAP client as Google instruct in order for the Gmail labels to work. See Recommended IMAP client settings

If you client is one of (iPhone, Thunderbird, Apple Mail, Outlook) then click the link and read Google's specific instructions for those clients.

Otherwise, you need to configure your client as follows:

Sending:

  • Do not save sent messages on the server. If your client is sending mail through Gmail's SMTP2 server, your sent messages will be automatically copied to the [Gmail]/Sent Mail folder.
  • DO save draft messages on the server. If you want your drafts in your mail client to sync correctly with Gmail's web interface, set your client to save drafts to the [Gmail]/Drafts folder.

Deleting:

  • Do not save deleted messages on the server. Messages that are deleted from an IMAP folder (except for those in [Gmail]/Spam or [Gmail]/Trash) only have that label removed and still exist in All Mail. Hence, your client doesn't need to store an extra copy of a deleted message.
  • Do not save deleted messages to your [Gmail]/Trash folder because this will delete a message in all folders.
  • Do not save deleted messages to your [Gmail]/All Mail folder as some clients will try to empty this folder and ultimately fail. This can lead to delayed mail access or excessive battery consumption on a mobile device.

Junk mail and spam:

  • Do not enable your client's junk mail filters. Gmail's spam filters also work in your IMAP client, and we recommend turning off any additional anti-spam or junk mail filters within your client. Your client's filter will attempt to download and classify all of your existing messages, which may slow down your client until the process is complete.

Note that the folder prefix [Gmail] is not used for all accounts. For a minority of users, the prefix [Google Mail] is used instead. This presumably applies to older accounts of users from the UK, Germany and Austria, where "Gmail" was initially rebranded to "Google Mail" following trademark disputes.