In Thunderbird, you can filter the email headings, e.g. "To:", "From:" and "Subject:", in addition to defining own headers to filter. A possible set-up is
to direct email from example@example.com to a separate folder.
All emails through Domainnameshop's mail servers are flagged with a header if they are likely to be spam. This header is called "X-Spam-Flag:", and it is set to "YES" if an email is likely to be spam.
How to configure spam filtering in Thunderbird: Choose "Tools | Message Filters" from the menu. The filtering configuration menu appears.
Click "New". The below menu appears:
Enter the filter name by substituting "Untitled Filter" with e.g. "Spamfilter". Check "Match any of the following". Choose "Subject" from the pulldown menu and then "Customize". The below menu appears:
Define the header to sort by, "X-Spam-Flag" in this example. Click
"Add" and then "OK". The below menu appears:
Define to sort by the "X-Spam-Flag"
header and that email containing the
search word "YES" are to be moved to the "Trash" folder.