# Processing Emails from Thunderbird (.mbox files or eml-files)

**URL:** <https://forum.knime.com/t/processing-emails-from-thunderbird-mbox-files-or-eml-files/66953>\
**Category:** KNIME Extensions\
**Tags:** text-processing\
**Created:** [May 12, 2023, 2:22pm UTC](https://forum.knime.com/t/processing-emails-from-thunderbird-mbox-files-or-eml-files/66953 "2023-05-12T14:22:42Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![kludikovsky](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/k/5e9695/32.png) [@kludikovsky](https://forum.knime.com/u/kludikovsky)\
**Post date:** [May 12, 2023, 2:22pm UTC](https://forum.knime.com/t/processing-emails-from-thunderbird-mbox-files-or-eml-files/66953/1 "2023-05-12T14:22:43Z")

</div>

Dear Knimer’s,

I am looking for a solution to process Emails from Thunderbird (on Linux). Either directly from the TB-files (read-only) or from the exported-files to either an .mbox- or multiple EML-files with the “ImportExportTools NG” add-on.  
I would require to get the whole header information of the emails extracted (including the ‘Received: from’, ‘X-Mozilla-…’ and any other info in the headers.

I haved read so far the recommendations at [Extract Text From Email](https://forum.knime.com/t/extract-text-from-email/38587) and tried the “Tika Parser” as well as the “mbox Reader”.  
The Tika Parser" didn’t return the header info, only the the Author, Date/time, Title , and Text.  
The ‘mbox Reader’ returned with an “Execute failed: Malformed input!” error. This might come from that this node expects a mbox-file, while the outputed format seems to be a mboxcl2-file (but I might be wrong).

Does anyone have any sugguestions how to I can get the required data into a table (or document.  
Is there a possibility to see the “Tika Parser” Code so that i can eventually expand the extraction fields.  
Or how the “mbox Reader” can be brought to operation and deliver the required data

Thanks.

PS: I dont need solutions to retrieve data from any kind of servers.

---

<div class="post-metadata">

**Author:** ![AlexanderFillbrunn](https://forum-cdn.knime.com/user_avatar/forum.knime.com/alexanderfillbrunn/32/357_2.png) [@AlexanderFillbrunn](https://forum.knime.com/u/AlexanderFillbrunn)\
**Post date:** [May 16, 2023, 7:38am UTC](https://forum.knime.com/t/processing-emails-from-thunderbird-mbox-files-or-eml-files/66953/2 "2023-05-16T07:38:36Z")

</div>

Hi @kludikovsky,  
I think there is no ready-made node, but eml is text-based (as long as you do not need to deal with attachments) and so I have created a component that may help: [Parse EML (Local) – KNIME Community Hub](https://hub.knime.com/alexanderfillbrunn/spaces/Public/latest/Components/Parse%20EML%20(Local)).  
Let me know if this is useful!  
Alexander

---

<div class="post-metadata">

**Author:** ![qqilihq](https://forum-cdn.knime.com/user_avatar/forum.knime.com/qqilihq/32/50_2.png) [@qqilihq](https://forum.knime.com/u/qqilihq)\
**Post date:** [May 16, 2023, 2:00pm UTC](https://forum.knime.com/t/processing-emails-from-thunderbird-mbox-files-or-eml-files/66953/3 "2023-05-16T14:00:00Z")

</div>

Hi kludikovsky,

thank you for your message on NodePit and your issue report regarding the Thunderbox files. I’m answering here, as it will be of benefit for the entire community.

On NodePit there’s an updated version of the [mbox Nodes](https://nodepit.com/product/mbox) [v2.1.0](https://nodepit.com/product/mbox/changelog) which allows you to change the parsing behavior, so that you should be able to process your Thunderbird exports properly. To use it, open your existing workflow and replace the now “deprecated” version of the mbox Reader with the new version from the node repository. Open the configuration and change the “From” setting from the default to the **second** entry.

To the background: Per default, the parser expects an `@` character in lines starting with `From`. Thunderbird’s export however also produces `From` lines which can look like this `From - Sun Aug 22 22:43:14 2021`.

Fingers crossed, and again thank you for your support in hepling us to improve these nodes!

-Philipp

> **[mbox Nodes — NodePit](https://nodepit.com/product/mbox)**
>
> Get emails from POP3 and IMAP servers and work with mbox files

---

<div class="post-metadata">

**Author:** ![kludikovsky](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/k/5e9695/32.png) [@kludikovsky](https://forum.knime.com/u/kludikovsky)\
**Post date:** [May 16, 2023, 4:46pm UTC](https://forum.knime.com/t/processing-emails-from-thunderbird-mbox-files-or-eml-files/66953/4 "2023-05-16T16:46:31Z")

</div>

H Alex,  
thanks a lot, but it’s been solved in the meantime.  
Nevertheless I will have a look at yout node.  
Kurt

---

<div class="post-metadata">

**Author:** ![kludikovsky](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/k/5e9695/32.png) [@kludikovsky](https://forum.knime.com/u/kludikovsky)\
**Post date:** [May 16, 2023, 4:47pm UTC](https://forum.knime.com/t/processing-emails-from-thunderbird-mbox-files-or-eml-files/66953/5 "2023-05-16T16:47:46Z")

</div>

Thanks a lot Philipp for the quick repsonse and solution.  
It works now a described.

- Kurt

---

<div class="post-metadata">

**Author:** ![system](https://forum-cdn.knime.com/uploads/default/original/1X/ab3ccf34482a0329361734a18199390177204f15.png) [@system](https://forum.knime.com/u/system)\
**Post date:** [May 23, 2023, 4:48pm UTC](https://forum.knime.com/t/processing-emails-from-thunderbird-mbox-files-or-eml-files/66953/6 "2023-05-23T16:48:01Z")

</div>

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.
