How to Analyze WeChat Group Chat Activity: A Complete Guide to a Free, Local Tool
Have you ever managed a WeChat group with hundreds of members and wondered who’s actually participating? You’re not alone. Most group owners and community managers face the same problem: the group looks alive on the surface, but real engagement is concentrated among a handful of people.
WeChat doesn’t offer any built-in analytics or member activity reports. All your chat history is stored in an encrypted local database on your computer, completely locked away from any statistics tools.
This guide walks you through a fully open-source solution that decrypts your local WeChat database on your own machine, extracts group chat statistics, and presents everything through a clean web-based dashboard. No cloud services, no third-party APIs, and your data never leaves your computer.
What This Tool Actually Does
Before diving into the setup, let’s be clear about what you’re building.
This tool performs three functions:
-
Decrypts your local WeChat chat database — WeChat stores all messages in an encrypted SQLite database. The tool extracts the encryption key from your running WeChat process and decrypts the data locally. -
Parses group chat messages and computes statistics — For every member in every group, it calculates message counts across different time windows. -
Serves a web dashboard — An interactive HTML page where you can browse all groups, sort members by activity, search by keyword, and drill into individual participation details.
Everything runs on your local machine. Nothing is uploaded anywhere.
What You Can Actually Learn from This
Here are practical scenarios where this kind of analysis is genuinely useful.
Community Management
You run a 300-member industry discussion group, but engagement has been declining. After running the analysis, you discover that only 15% of members have posted in the last 30 days. That’s a concrete signal — not a gut feeling — that your content strategy or group structure needs rethinking.
Team Communication Audit
You manage multiple project teams, each with its own WeChat group. By comparing activity levels across groups, you can identify which teams communicate effectively and which ones have gone quiet. Members tagged as “inactive for 6 months” in a project coordination group might need a direct check-in.
Cleaning Up Dead Groups
Most people belong to dozens of groups, but many of them are effectively dead. Instead of scrolling through each group manually, you get a clear picture: total messages, active members, and the ratio of never-spoken members. This makes it easy to decide which groups to leave or restructure.
How the Tool Works Under the Hood
Understanding the three-stage pipeline helps when something goes wrong during setup.
Stage 1: Key Extraction and Database Decryption
On macOS, WeChat encrypts its chat database using keys stored in process memory. A companion open-source project called wechat-decrypt (by ylytdeng) uses macOS-specific mach_vm system calls to read the encryption key directly from the running WeChat process. Once the key is obtained, every encrypted table in the SQLite database is decrypted and saved as a standard, readable SQLite file.
Stage 2: Data Parsing and Statistics
With the decrypted database in hand, the main analysis script iterates through all group chat message tables. For each group member, it computes:
| Metric | What It Measures |
|---|---|
| Total messages | All-time message count for this member in the group |
| Last 1 month | Messages sent in the past 30 days |
| Last 3 months | Messages sent in the past 90 days |
| Last 6 months | Messages sent in the past 180 days |
| Last seen | The date of the member’s most recent message |
Stage 3: Visualization
The statistics are rendered in a browser-based dashboard built with plain HTML and JavaScript. No backend server framework is needed — a simple Python HTTP server is enough to serve the static files and the JSON data.
Prerequisites: What You Need Before Starting
This solution currently works only on macOS. The key extraction step relies on macOS-specific system calls that don’t have equivalents on Windows or Linux.
Make sure you have the following ready:
-
macOS — Ventura or later is recommended -
Python 3.9 or higher -
Xcode Command Line Tools — provides the cccompiler needed to build the key extraction binary -
WeChat desktop client — logged in and working normally -
Administrator access — required for the code signing step
Important: This tool is intended for analyzing your own WeChat chat records only. Do not use it to access data you are not authorized to read. After every WeChat client update, you will need to redo the code signing and key extraction steps.
Step-by-Step Setup and Usage
Follow these steps in order. Each one includes an explanation of what’s happening and why.
Step 1: Install the Decryption Engine
Open Terminal and run the following commands:
# Clone the wechat-decrypt repository
git clone https://github.com/ylytdeng/wechat-decrypt.git ~/wechat-decrypt
cd ~/wechat-decrypt
# Create a Python virtual environment and install dependencies
python3 -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt
# Compile the macOS key extraction tool
cc -O2 -o find_all_keys_macos find_all_keys_macos.c -framework Foundation
Here’s what each command does:
-
git clone: Downloads the decryption engine source code to your local machine. -
python3 -m venv: Creates an isolated Python environment so the dependencies don’t interfere with other projects. -
pip install: Installs the Python libraries that the decryption engine depends on. -
cc: Compiles a small C program that uses macOS’s Foundation framework to read memory from the WeChat process. This is the core binary that extracts encryption keys.
Step 2: Re-Sign the WeChat Application
This is the most critical step. macOS’s System Integrity Protection (SIP) prevents external processes from reading the memory space of signed applications. By re-signing WeChat with an ad-hoc signature, you remove this restriction for this specific app.
# Completely quit WeChat first
killall WeChat
# Re-sign the WeChat application with an ad-hoc signature
sudo codesign --force --sign - /Applications/WeChat.app
# Reopen WeChat and log in
open /Applications/WeChat.app
A few things to keep in mind:
-
After re-signing, macOS may show a warning that the developer cannot be verified. This is expected. Click “Open” to proceed. -
When WeChat auto-updates in the future, the signature reverts to the official one. You’ll need to repeat this step after each update. -
The killallcommand ensures no WeChat processes are running during the re-signing. If it says “No matching processes,” that’s fine — just proceed.
Step 3: Install the Analysis Tool
git clone https://github.com/punk2898/wechat-group-stats.git
cd wechat-group-stats
Here’s what the project directory looks like:
wechat-group-stats/
├── wechat-stats.py # Core analysis script
├── wechat-server.py # Web server entry point
├── dashboard.html # Dashboard frontend page
├── group-names.example.json # Group name mapping template (optional)
├── README.md
└── .gitignore
Step 4: Run Your First Decryption and Analysis
Make sure WeChat is running and logged in, then execute:
# Decrypt the database first
python3 wechat-stats.py --decrypt
This calls the wechat-decrypt engine in the background, extracts the encryption key from WeChat’s memory, decrypts the SQLite database, and saves the readable version locally.
After decryption completes, list all detected groups:
python3 wechat-stats.py
You’ll see output similar to:
Found 15 groups:
1. 1234567890@chatroom - Project Alpha Core
2. 9876543210@chatroom - Book Club
...
Step 5: Assign Readable Group Names (Optional)
By default, the tool identifies groups by their internal WeChat group ID, which isn’t human-friendly. You can assign a display name to any group:
python3 wechat-stats.py --set-name "groupID@chatroom" "My Project Team"
Once set, all subsequent outputs will use your custom name instead of the raw ID.
Step 6: Analyze a Specific Group
To drill into a particular group’s member statistics:
python3 wechat-stats.py --group "My Project Team"
This outputs a detailed breakdown for every member: total messages, 1-month activity, 3-month activity, 6-month activity, last message date, and an activity tier label.
Step 7: Launch the Web Dashboard
python3 wechat-server.py
You should see: Dashboard running at http://localhost:8080/dashboard.html
Open that URL in your browser to access the full interactive dashboard.
For daily use after initial setup, you only need two commands:
cd wechat-group-stats
python3 wechat-server.py
# Then open your browser and click refresh
Navigating the Dashboard

The dashboard is a single-page application that displays all your group data in a sortable, searchable table. Here’s what you can do:
-
Sort by any column: Click on column headers like “Total Messages” or “Active Last Month” to sort ascending or descending. This lets you instantly find the most or least active groups. -
Search and filter: Type a keyword (e.g., “work” or “family”) in the search box to filter groups in real time. -
Expand member details: Click on any group row to expand it and see individual member statistics — message counts, activity tiers, and last active dates. -
One-click refresh: Hit the refresh button to re-run the analysis with the latest data.
Understanding the Output Data Format
Results are saved by default to wechat-stats.json. Here’s what the structure looks like:
{
"groups": [{
"name": "My Group",
"total_members": 414,
"total_messages": 10577,
"active_1month": 62,
"never_spoken": 254,
"all_members": [{
"name": "Zhang San",
"total": 648,
"last_1month": 5,
"last_3month": 10,
"last_6month": 648,
"tag": "Active",
"last_seen": "2025-06-03"
}]
}]
}
Key Fields Explained
| Field | Type | Description |
|---|---|---|
total_members |
Integer | Total number of members in the group |
total_messages |
Integer | Total message count across all time |
active_1month |
Integer | Number of members who sent at least one message in the past 30 days |
never_spoken |
Integer | Number of members who have never sent a message since joining |
all_members |
Array | Per-member statistics including message counts and activity tier |
tag |
String | Activity tier label assigned automatically |
How Activity Tiers Are Determined
The tool classifies each member into one of six tiers based on their message frequency and recency:
| Tier | What It Means | Typical Pattern |
|---|---|---|
| 🔥 Ultra-active | Extremely high message volume, still active in the past month | Group admins, discussion leaders |
| 🟢 Active | Consistent posting history, participated recently | Regular participants |
| 🟡 Occasional | Low volume but intermittent participation over time | Silent but occasionally chimes in |
| 🟠 Low-frequency | Very few messages, almost nothing in the past month | The silent majority |
| 🔴 Faded | No recent activity, but had historical messages | Was once active, then disappeared |
| 💀 Dead account | No messages at all over an extremely long period | May have uninstalled WeChat or abandoned the group entirely |
One pattern you’ll notice quickly: in most groups, the “never spoken” count is much higher than expected. In a 400-member group, it’s common to find that over 60% of members have never sent a single message. This is a strong indicator that raw member count does not equal actual engagement.
Complete Command Reference
Not every use case requires the same command. Here’s a quick lookup:
| Command | What It Does |
|---|---|
python3 wechat-stats.py |
List all detected WeChat groups |
python3 wechat-stats.py --group "keyword" |
Filter and analyze groups matching a keyword |
python3 wechat-stats.py --decrypt |
Decrypt the database first, then analyze |
python3 wechat-stats.py --set-name "groupID" "display name" |
Assign a readable name to a specific group |
python3 wechat-stats.py --output custom.json |
Save results to a custom file path |
python3 wechat-stats.py --wechat-decrypt-dir /path/ |
Specify a custom install path for wechat-decrypt |
Real-World Example
Suppose you want to analyze a group called “Product Discussion” and your wechat-decrypt is installed in a non-default location:
python3 wechat-stats.py --decrypt \
--wechat-decrypt-dir ~/tools/wechat-decrypt \
--group "Product Discussion"
Frequently Asked Questions
Do I have to use macOS? Can I run this on Windows?
Yes, macOS is currently required. The key extraction step uses macOS-specific mach_vm system calls to read encryption keys from WeChat’s running process. There is no equivalent mechanism available on Windows or Linux at this time.
Will I lose my analysis data when WeChat updates?
No. The decrypted SQLite database files remain on your local disk. What you do need to do is repeat the re-signing and key extraction steps after each WeChat client update. Your previously exported JSON data is unaffected.
Is it normal for the “never spoken” count to be so high?
Yes, this is very common. Many users join groups and never actively participate — especially in large notification-style groups, or when they were added by someone else. The never_spoken metric is specifically designed to surface this pattern. If the percentage is unusually high, it may be worth reconsidering how the group is structured or managed.
Does the analysis include my own messages?
Yes. If you have sent messages in a group, your own account will appear in the member list and be counted like any other member.
Is any data sent to external servers?
Absolutely not. All decryption and analysis happen entirely on your local machine. The web dashboard is served from localhost:8080 and does not transmit any data over the network.
Can I automate this to run on a schedule?
Yes. You can write a shell script that chains the decryption and analysis commands, then schedule it with crontab. Because the output is standard JSON, it’s also straightforward to pipe into other tools or scripts for further processing.
What if group names show up as garbled text?
Try using the --set-name parameter to manually assign a readable name. Garbled group names are usually caused by encoding mismatches between WeChat’s internal format and the system locale.
What does the “last seen” date represent?
It’s the date of the member’s most recent message in that group. If the date is far in the past, the member has not participated in group discussions for a long time.
Patterns You’ll Notice Once You Start Tracking
After running this tool across multiple groups over time, a few patterns tend to emerge consistently.
The silent majority is larger than you think. In a group of 500 people, it’s typical to see only 30–50 members post anything in a given month. The rest are present in name only.
Engagement follows a power law. Roughly 80% of messages come from fewer than 20% of members. This concentration is even steeper in larger groups.
“Dead” groups are easy to spot. When the never-spoken ratio exceeds 70% and the ultra-active tier has only 1–2 people, the group is essentially a one-way broadcast channel. Restructuring into a smaller, more focused group often yields better results.
Activity decays predictably. New groups start with high engagement, then settle into a stable core of regular contributors within 2–3 months. Tracking this curve helps you intervene early if participation drops.
Quick Reference: From Zero to Dashboard
Here’s the complete minimal checklist to get everything running:
-
[ ] Confirm you’re on macOS with Xcode Command Line Tools installed -
[ ] Clone and set up wechat-decrypt, compile the key extraction binary -
[ ] Quit WeChat completely, then run sudo codesign --force --sign - /Applications/WeChat.app -
[ ] Reopen WeChat and log back in -
[ ] Clone the wechat-group-statsrepository -
[ ] Run python3 wechat-stats.py --decryptto decrypt the database -
[ ] Run python3 wechat-stats.pyto list all detected groups -
[ ] (Optional) Use --set-nameto assign friendly group names -
[ ] Run python3 wechat-server.pyto start the dashboard -
[ ] Open http://localhost:8080/dashboard.htmlin your browser
Final Thoughts
The real value of this tool isn’t in the numbers themselves — it’s in what the numbers reveal. Group chat activity analysis turns opaque social dynamics into something you can actually measure and act on.
Because everything runs locally with no external dependencies, you don’t have to worry about data privacy or third-party access. The setup takes about 15 minutes the first time, and after that, checking your group stats is as simple as opening a browser tab.
Whether you’re managing a community, auditing team communication, or just curious about how your own groups actually function, this tool gives you something most people never have: a clear, honest picture of who’s really talking — and who isn’t.

