Simple python script to display mails counts grouped by sender. Useful to free up space on your mailbox.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

Mbox Sender Frequency

This very small tool will display mail counts grouped by sender. This is helpful to identify automated notification mails that you may want to delete from your mailbox to free up some space.

If you're curious, I wrote a blogpost in which I explain the context in which I needed this script, namely to leave GMail.


Clone this repo somewhere or download the standalone python script. You can then simply use it with :

python [-h] [--threshold THRESHOLD] [--group-by-email]

for example :

usage example

Getting your mbox file from GMail

Head to Google Takeout, select Mails, and opt for the file download link version. Then be patient, and you will receive a mail with a link to your own mbox file within a few hours / days.


This was not optimized at all, so it may be quite slow, however it ran on my 4GB file within a few minutes, which was acceptable to me.