Messenger Counter is a python script that counts messages from Facebook Messenger and shows various statistics.
If you are interested in contributing to this repository, pull requests are much appreciated.
Note: To use this software you need to download your data directly from Facebook (in JSON format). How to download my data?
pip install messenger-counter
- Run the following command to open CLI. You can provide path to .zip file (or extracted folder) as an argument.
python -m mc facebook-YourName.zip
- Wait for
>
to appear and use following commands for different statistics (examples below)
>command [options]
Available commands:
count [mcw] [s]
— Counts messages, characters and words. You can uses
to save data to .json file.stats [converstion] [-c]
— Displays statistics for counted messages. You can specify conversation for detailed statistics and use -c for character statistics.user [name]
— Detailed statistics for specific personyearly [conversation]
— Number of messages per year. You can specify conversation for more precise statistics.daily [conversation]
— Number of messages daily.hours [conversation]
— Average number of messages by hour throughout the day.
Show general statistics of all conversations
stats
Show messages statistics for specific conversation. (you can list all conversations by running previous example)
stats JohnDoe
Program allows you to write only the beginning of the conversation name. It will return first matching occurrence. (Works exactly as the previous example)
stats Joh
Shows how many messages did the person send grouped by conversation.
user "John Doe"
Shows how many messages on average have you send and received grouped by time of the day.
daily
Similar to previous one, but limited to one conversation.
daily John
Get started:
import counter as mc
# Available soon
- Select Settings & Privacy in the top right of Facebook, then click Settings.
- In the left column, click Your Facebook Information.
- Click on Download Your Information.
- Deselect all and select "Messages" category by clicking the box on the right side.
- It is necessary to choose JSON format of your download request.
- Click Create File to confirm the download request.
- Facebook will notify you when your copy will be ready to download.
- Go to the Available Files section.
- Click Download and enter your password.
Messenger Counter is licenced under MIT Licence.