Export and analyze iMessage conversations from macOS SQLite database
Project description
iMessage Wrapped
Export and analyze your iMessage conversations from the macOS SQLite database.
Quick Install & Run
pip install imessage-wrapped
imexport analyze
That's it! By default, the command will:
- 🔄 Auto-export your messages (if not already exported)
- 📊 Analyze your messaging patterns
- ☁️ Upload anonymized statistics
- 🔗 Give you a shareable URL like:
https://imessage-wrapped.fly.dev/2025/abc123xyz
Want to see full details in the terminal instead? Use imexport analyze --no-share
Features
✅ Dashboard - Interactive visualizations of your messaging patterns
✅ Easy Sharing - One command to upload and get a shareable link
✅ Secure - HTTPS, encrypted database
✅ Deploy Anywhere - Fly.io ready (free tier available)
🔒 Data Privacy
Your message content NEVER leaves your computer.
By default, we only upload aggregated statistics to create your shareable link. Here's exactly what is and isn't uploaded:
✅ What IS Uploaded (Statistics Only)
- Counts: Total messages sent/received, tapbacks given/received, attachments, etc.
- Averages: Message length, response times, punctuation usage
- Distributions: Hour of day, day of week, month patterns
- Emojis: Which emojis you used and how often
- Dates: Your busiest messaging days, streak lengths
- Anonymized Identifiers: Contact identifiers are SHA256-hashed (e.g.,
phone_a3b2c1d4e5f6)
❌ What is NOT Uploaded (Stays Private)
- Message Text: No actual message content is ever sent
- Contact Names: All names are stripped out before upload
- Phone Numbers/Emails: Original identifiers are one-way hashed
- Conversation Content: No snippets, samples, or quotes
- Attachments: No photos, videos, or file content
- Personal Info: Nothing that could identify you or your contacts
Usage
As a Library
from imessage_wrapped import MessageService, Exporter
service = MessageService()
data = service.export_year(2025)
exporter = Exporter()
exporter.export_to_file(data, "messages_2025.json")
See example_usage.py for a complete working example.
As a CLI
After installation, use the imexport command:
# Export current year (default)
imexport export
# Export specific year
imexport export --year 2024
# Custom output path
imexport export --output my_messages.json
# Custom database path (for testing)
imexport export --database /path/to/test/chat.db
# Compact JSON (no indentation)
imexport export --indent 0
# Analyze and share (default behavior)
imexport analyze
# Analyze with full terminal output (no sharing)
imexport analyze --no-share
# Show help
imexport --help
Alternatively, run without installation:
python -m imessage_wrapped export --year 2024
CLI Commands:
imexport export: Export iMessage conversations to JSONimexport analyze: Analyze and share your wrapped (auto-exports if needed, use--no-sharefor full terminal output)
Requirements
- Python 3.10+
- macOS with Full Disk Access permission
richlibrary for terminal output
Installation
Install in Development Mode
pip install -e .
This installs the package and creates the imexport command.
Install Dependencies Only
pip install -r requirements.txt
macOS Permissions
This application requires Full Disk Access to read the iMessage database:
- Open System Settings
- Go to Privacy & Security → Full Disk Access
- Add Terminal or your Python application
- Restart the application
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file imessage_wrapped-0.1.7.tar.gz.
File metadata
- Download URL: imessage_wrapped-0.1.7.tar.gz
- Upload date:
- Size: 22.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fb25555f07a16715ed9646b2914fcc425db250a8604071c2f710f9548cf75443
|
|
| MD5 |
159e9f20911ce5f621f89c09954ea1dd
|
|
| BLAKE2b-256 |
531056f1550fb6149ec0b4f6823436fa708e2585b0494290f5f83f2c182c63f9
|
File details
Details for the file imessage_wrapped-0.1.7-py3-none-any.whl.
File metadata
- Download URL: imessage_wrapped-0.1.7-py3-none-any.whl
- Upload date:
- Size: 24.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
075bed7de116d2bb38b32785d969a1e175deeb8239d7a756e6daeb0e36eb296f
|
|
| MD5 |
425ef76fe0e3b05a7eb99e8b4d89c30f
|
|
| BLAKE2b-256 |
3e2b17d6b2f0055f994d0fdbcea576dec081d4ded3388f9ea1c2024d23748a15
|