MBOX CSV
File conversion

Convert MBOX to CSV

QUICK ANSWER
Is it possible to convert MBOX to CSV?
Yes - MBOX converts to CSV.

MBOX-to-CSV means exporting message metadata (From, To, Subject, Date) as rows; full message bodies do not fit cleanly in a CSV cell. Python's mailbox module handles any size .mbox file and is the most reliable free option.

Also to CSV: DTA · HVE · XFDF

On this page

Tested on macOS, Windows & Linux
Last verified Oct 2026

More free converters

HEIC, PNG, WEBP, MP3 and more - every tool here is free.

Open the toolbox

Why convert MBOX to CSV?

Converting MBOX to CSV gives you a spreadsheet you can sort, filter, and analyze in Excel or Google Sheets. Common uses are auditing a mailing list archive, counting messages per sender, or reviewing a Gmail Takeout export without opening an email client.

How to convert MBOX to CSV

Python (mailbox module) FREE

Write a short Python 3 script using the built-in mailbox module to iterate over messages and write From, To, Subject, and Date fields to a .csv using the csv module.

About these formats

Quality & what to watch

  • Only metadata transfers cleanly - From, To, Subject, Date fit as CSV columns; message bodies and attachments do not.
  • A Gmail Takeout .mbox can be several gigabytes; the Python mailbox module reads the file sequentially without loading everything into memory at once.
  • Avoid uploading an .mbox to online converters - it contains your complete email history and is highly sensitive personal data.

Frequently asked questions

Can I include the message body in the CSV?
You can add a body column using msg.get_payload(), but HTML and MIME-encoded content will appear raw and may be very long.
Does Python work on Windows for this?
Yes - Python 3 runs on Windows, macOS, and Linux, and the mailbox module is built in with no extra installation required.
What if my .mbox has encoding errors?
MBOX has sub-variants (mboxo, mboxrd, mboxcl, mboxcl2); Python's mailbox module handles the common cases, but a malformed .mbox may produce garbled rows in some fields.