A small program written in Python 3 that lets you see statistics of any Facebook Messenger conversation. This project started of as a Valentines day surprise for my girlfriend inspired by this Reddit post.
The program fetches data such as:
It also generates a PDF containing the following plots (see pictures below)





Download your Facebook data by following these instructions and chosing the format to be JSON. Note that you only have to download your messages in order for this program to work.
git clone https://github.com/davidkrantz/FacebookChatStatistics.git
in your terminal.
requirements.txt file and should be easily installed using pip withpip3 install -r /path/to/requirements.txt
NOTE: The script requires version <=1.7.0 of the package emoji.
FacebookChatStatistics folder just created. Run the script as below with the path to your JSON conversation as an argument, for examplepython3 facebook_chat_statistics.py /Path/To/Conversation.json
This should generate a PDF including figures similar to the ones above.
NOTE: The number of top emojis is default set to 10, but can easily be changed to some other integer by changing the line nbr_of_top_emojis = 10 in facebook_chat_statistics.py.