Gmail IMAP – Solving the [Gmail] separation

When you are using a Gmail account over IMAP in Outlook, you’ll also automatically get an [Gmail] or [Google Mail] folder containing all the “system folders” of Gmail itself.

To break yourself out of this additional subfolder and have all these folders listed directly under your mailbox in Outlook, you can set a root folder for your Gmail IMAP account. However, this has an effect on any Labels that you might use in Gmail. Luckily, there is a workaround for this as well.


Setting a root folder for your Gmail account

To make the change, you’ll have to go to the “Advanced Settings” tab of your account configuration;

  1. Open your Account Settings dialog;
    • Outlook 2003
      Tools-> E-mail Accounts…-> option: View or change existing e-mail accounts-> button Next
    • Outlook 2007
      Tools-> Account Settings…-> tab tab E-mail
    • Outlook 2010
      File-> section Info-> button Account Settings-> Account Settings…-> tab E-mail
  2. Double click on your Gmail IMAP account to open the account settings.
  3. Click on the More Settings… button.
  4. Select the Advanced tab.
  5. At the bottom, set the “Root folder path” option to; [Gmail]
     

    Setting the Root folder path in your IMAP account settings.
    Setting the Root folder path in your IMAP account settings.

  6. After setting the option and confirming your way out of all of the opened dialogs, you’ll get a notification that your IMAP cache needs to be rebuild.
  7. In some cases, you’ll need to set the Sent Items and Deleted Items folder for the Gmail IMAP account again.
Before - Setting a root path for your Gmail account will free you from the [Gmail] folder structure.
Before
After - Setting a root path for your Gmail account will free you from the [Gmail] folder structure.
After
Setting a root path for your Gmail account will free you from the [Gmail] folder structure.

Getting your Labels back in Outlook

Since you are now using [Gmail] as the mailbox root folder and Labels are created on a higher level, you won’t be able to see your Gmail Label folders in Outlook.

A way around this is to prefix each of your Labels with [Gmail]/. So a label called My Label 1 should be renamed to [Gmail]/My Label 1 via the Gmail web interface.

Instead of prefixing your Labels, you can also create a Label called [Gmail] and configure My Label 1 as a nested Label of the [Gmail] Label.

Before - Setting a root path for your Gmail account will free you from the [Gmail] folder structure.
Gmail
After - Setting a root path for your Gmail account will free you from the [Gmail] folder structure.
Outlook
Prefix your labels with [Gmail]/, or make them a nested label of the [Gmail] label in the web interface, will make them available in Outlook again.

Note:
Any changes you make to the names and the structure of your folders via the Gmail web interface won’t be visible in Outlook until you restart Outlook.

Grouping your Labels together

As you are now working of the [Gmail] root folder in Outlook, you’ll see all your Labels directly under your main mailbox. This might end up being a long list and make the Gmail “system folders” harder to recognize (now you know why they grouped them under a [Gmail] folder ;-) ).

To solve this, create another Label under the [Gmail] Label in the web interface and call it for instance “Labels”. Now you can make all your own Labels a nested Label of the Labels folder.

As an alternative, you can also prefix your Labels with [Gmail]/Labels/ since the / character is being used as a separator to indicate a subfolder.

Before - Setting a root path for your Gmail account will free you from the [Gmail] folder structure.
Gmail
After - Setting a root path for your Gmail account will free you from the [Gmail] folder structure.
Outlook
Prefix your labels with [Gmail]/Labels, or nest them under Labels in the web interface, will group them together in Outlook.

Creating subfolders in Outlook and Labels in Gmail

Gmail itself doesn’t really use/understand the concept of subfolders; everything is a Label. If you were to create a subfolder under the Inbox folder, you’ll actually be creating the Label INBOX/My subfolder in the web interface of Gmail.

Once the mailbox is rooted to the [Gmail] folder, and since the Inbox folder lives outside it, unfortunately it is not possible anymore to create or access subfolders directly under the Inbox folder as you would be able to if it wasn’t rooted. Trying to create a subfolder for the Inbox folder will then result in the following error;

Cannot create the folder. Cannot create or navigate to the folder. You cannot create or navigate to subfolders of your Inbox when you have a non-empty Root Folder Path. (click on image to enlarge)
Setting a [Gmail] root folder prevents you from creating subfolders under the Inbox folder in Outlook. (click on image to enlarge)

To work around this, you can create a new label via the Gmail web interface called;
[Gmail]/Inbox/My subfolder

Unlike any INBOX/name subfolders, folders prefixed with [GMAIL]/Inbox/ will show up in Outlook as a subfolder of the Inbox folder even when the mailbox is rooted to [Gmail].

Before - Setting a root path for your Gmail account will free you from the [Gmail] folder structure.
Gmail
After - Setting a root path for your Gmail account will free you from the [Gmail] folder structure.
Outlook
Prefix your labels with [Gmail]/Inbox, or nest them under the Inbox label in the web interface, will allow you to create subfolders under the Inbox folder.

Note:
This is only required for any folder which should be a direct subfolder of the Inbox folder. Any subsequent subfolders can be directly created in Outlook without errors.
 
However, in the web interface of Gmail, this folder will be created with the name “INBOX” instead of “Inbox” which could separate the folders again in Outlook after a restart. In that case, you’ll have to rename the “INBOX” part of the label to “Inbox” in the Gmail web interface and restart Outlook.

Final thoughts

How useful is this change? Well, if you are also often using the web interface of Gmail and are a heavy user of Labels, I’d say it is not very useful at all. After all, instead of having the [Gmail] folder structure in Outlook, you’d then have it in the web interface. Combine that with the amount of work it is to set it up and the 40 character limit of Labels (including the characters of parent folders!), it’s probably not worth the trouble.

However, if you mainly use Outlook (or any another mail client for that matter), sort your mail into subfolders and don’t really care about the Gmail web interface and its Labels, setting a root folder would make sense. The result would be a flatter and more consistent folder structure in Outlook.