32

I have Thunderbird connecting to a Gmail account via IMAP, so Gmail labels show up as folders in Thunderbird. Moving items to folders in Thunderbird causes labels to be applied in Gmail.

However, Thunderbird also has its own tagging mechanism where you can apply a color code and tag by pressing keys 1-5 on a message. Is there any way to propagate these tags to corresponding Gmail labels?

3
  • can't this be achieved with a plugin?
    – user69601
    Feb 28, 2011 at 23:02
  • 2
    The fundamental difference is that gmail provides a many-to-many relationship between emails and labels. And what a concept. Very smart. A label could be a path (a folder), a degree of urgency (important), to-do, to-follow up, to trash, to archive or any concept. It is just a label or attribute of an email object. Then you can query based on such labels.
    – user113089
    Jan 11, 2012 at 2:30
  • 2
    Thunderbird's tags are also many-to-many. Feb 23, 2021 at 0:40

5 Answers 5

6

It seems more people wanted this feature, but you should realize Thunderbird's folders are Gmail labels. Therefore Thunderbird's tags are not the same as the labels, in other words: there is no Gmail counterpart.

So as of yet I don't think this feature is available. I will check to see if I can find a way to filter your inbox for tags (moving them into folders).


From the Thunderbird Knowledge Base on filters

Filtering based on Tags

Thunderbird doesn't have explicit support for filtering by tags but you can select Custom Headers from the leftmost list box while editing the filter rule and add support for X-Mozilla-Keys, and then test whether it "contains" that tag. Thunderbird uses that header to store tags. For example, X-Mozilla-Keys: forum fyi indicates the message has the forum and fyi tags.

IMAP accounts store tags using message attributes instead, so its not possible to do that with messages stored in remote folders. If you copy the message to a local folder it currently doesn't add a X-Mozilla-Keys header with the tags, though it will add a empty X-Mozilla-Keys header when you compact it

Here's a link to the Knowledge Base on tags

Thunderbird has limited support for tags in message filters. It just supports set a tag as a action. However, if you add a custom header for the tag, or specify it using "Customize" in the leftmost list box you can test for tags. Since you can have multiple tags for a message its recommended you test whether X-Mozilla-Keys: "contains" a tag rather than using "is".

View -> Sort by -> Tags can sort the messages in a folder based on the tag. View -> Messages -> Tags can be used to display just the messages with the selected tag. The View list box has a similar menu command but it is not visible in the toolbar in version 2.x. Right click on the toolbar, drag and drop the View control to the toolbar, and press OK to add it. You can also create a custom view using View -> Messages -> Customize that displays just the messages with the desired tags.

5
  • 2
    Short version: can't be done!
    – Ivo Flipse
    Sep 29, 2009 at 17:11
  • That's too bad. The color-coded tags are nice for visually flagging disposition of messages, even if they aren't really essential.
    – Brad Payne
    Sep 30, 2009 at 14:33
  • 2
    What happens to emails that have more than one label? How is this handled in Thunderbird?
    – felideon
    Oct 28, 2010 at 13:05
  • I fear I don't know the answer to that @felideon and I don't use Thunderbird myself, so I can't verify
    – Ivo Flipse
    Oct 28, 2010 at 17:58
  • 2
    "Thunderbird's folders are Gmail labels" not exactly as labeled messages can be found within the inbox of each account. I want some messages to be in my inbox, and yet still be labeled. Sep 19, 2011 at 1:26
5

In principle, it really could be done. See the IMAP extensions that Google added for their servers:

http://code.google.com/apis/gmail/imap/

If Mozilla would use these extensions, you could pull the GMail labels down and apply them to a message as tags. You can then use the popular "Conversation view" addon to essentially get GMail's web interface without the web interface.

2

I was also looking for a way to syncronize gmail labels and thunderbird tags.
I (sortof) found a way ...
The gmail label to a message gets applied from my imap gmail filter. And I create an like-named tag in Thunderbird.

  • In gmail in a browser: Settings >> Filters >> Create a new Filter:
    eg: Matches: subject:([nbusers])
    Do this: Skip Inbox, Apply label "[Gmail]/nbusers"

  • In Thunderbird:

    1. Create a new Tag with the same name as the gmail label.
    2. Tools >> Message Filters >> Select from "Filters for:" dropdown box >> New...
      Add your criteria (eg: Subject contains [nbusers])
      Add your actions (eg: "Tag Message", and select the new tag you created.)
    3. To apply to existing messages, in the "Message Filters" window,
      Highlight your new filter,
      Select the gmail folder in the "Run selected filter(s) on" dropdown box at the bottom of the window
      (eg: [gmail/nbusers]), and
      Click the "Run Now" button.

I said "sortof" above, because it's not really synchronized in an automatic sense. You've got to set it up in both tools.

An update: I tried the mozilla-x-keys method for my thunderbird filter. It didn't work.
Also in my above example, my gmail filter has "skip inbox". This negates the thunderbird filter. It causes the thunderbird filter to not see the incoming message and so it doesn't act on it. It works if you take off the "skip inbox" criteria.

1
  • 1
    The algorithm you describe could make a good extension
    – PPC
    Jul 6, 2012 at 17:24
2

If you right-click on the email and choose Copy to <folder> where <folder> is the folder matching your desired label name, it will apply the <folder> label to the email in Gmail.

1
  • This seems to be working well for me too. Jan 10, 2019 at 14:11
1

There is an extension allowing basic support for Gmail Labels:

https://addons.mozilla.org/en-US/thunderbird/addon/gmailbuttons/

You need version 0.7.0b1 of this add-on: you can find it at the bottom of the page in the "Development Channel" block.

The labels will appear at the top of the mail. You can remove them by clicking on the small cross "x".

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .