需要能访问 iMessage 数据库文件,通常要在 macOS 上读取;二进制安装细节在子目录 README 中,需另行查看;README 未说明默认端口等运行参数
把 iMessage 数据导出为 txt 或 html 并做数据库诊断的跨平台开源工具
把 Mac 上的 iMessage 聊天记录导出成可读文件,还能跑诊断排查数据库问题,适合备份和迁移聊天数据。
核心能力
- 导出为 txt 或 html 等开放便携格式
- 保留图片、视频、音频等多媒体附件
- 支持 iMessage、RCS、SMS、MMS 及群聊
- 覆盖 Tapbacks、贴纸、编辑消息等特性
- 对 iMessage 数据库运行诊断排查问题
容易踩的坑
- 5.0.1Speckled Clarkia最新正式版2026-10-29 · 2026-10-29 04:46 UTC
iMessage Exporter 5.0.1: Speckled Clarkia contains the following fixes and improvements:
- New Features
- Contacts-based conversation merging
- Combine phone numbers and email addresses belonging to one person, including linked Contacts cards on macOS and iOS
- Merge conversations split across those addresses, including group chats
- Preserve separate group chats with different names unless Messages explicitly links them
- Skip ambiguous identity matches when an address belongs to multiple Contacts cards
- Allow
--contacts-path(-n) to override the Contacts database in encrypted and unencrypted iOS backups
- Contacts-based conversation merging
- Performance
- Read message bodies and edit histories with message rows instead of fetching them separately for each message
- Parse body data directly from query results, avoiding intermediate buffers in the main decoding path
- Replace the separate payload-presence query with a flag in the message query
- Bug Fixes
- Fix inflated poll vote counts when participants change selections or Messages repeats vote updates for #823
- Fix null values in archived app-message payloads and render links as plain URLs when preview metadata is absent or null for #805
- Preserve recovered body components and edit history when text recovery fails
- Keep attachments and handwriting from recovered deleted messages in their conversation’s attachment directory for #827
- Route messages from linked chat rows without participant records to their conversation instead of the orphaned transcript
- Fix incorrect contact matches caused by country-code collisions and iOS search-index phone fragments
- Reject unmatched conversation filters even when date filters are supplied
- Reject out-of-range handwriting dimensions and handle empty text-rendering canvases
- Fix a performance regression where the bundled SQLite 3.54 update recompiled cached queries for every message for #839
- Enhancements
- Improve conversation naming and filtering
- Use one filename and attachment directory for every chat row in a merged conversation
- Choose consistent contact names and fallback addresses, honoring linked contacts’ preferred names
- List each participant once and improve long filename truncation and remaining-participant counts
- Match conversation filters against every Messages address belonging to a grouped participant
- Clarify diagnostic counts and report participants and conversations merged through Contacts
- Improve database and backup path errors for #829, #808, #647, #590, #493, and #359
- Distinguish missing paths, permission failures, invalid SQLite files, and databases without Messages data
- Suggest database and backup locations based on files found on disk
- Improve default home-directory resolution, including Windows support
- Improve conversation naming and filtering
- API Changes
- Breaking (migration guide)
- Decode message text, body components, and edit history during row loading; remove separate body-decoding calls
- Replace callback streaming and generic query/cache traits with prepared-statement iteration and concrete APIs
- Separate participant identity groups from stored addresses and use those groups for chat deduplication
- Return decoded timestamps in UTC and accept explicit timezones for date filtering and presentation
- Separate exported attachment paths and media types from database rows
- Revise diagnostic fields, error variants, and public module paths
- Ergonomic
- Re-export
chrono,plist, andrusqlitefromimessage_database
- Re-export
- Breaking (migration guide)
- Miscellaneous
- Exclude test fixtures from the published library package
- Recommend
cargo install --locked - Expand regression coverage, consolidate exporter tests, and enforce formatting in CI
- New Features
- 5.0.0Speckled Clarkia2026-10-29 · 2026-10-29 03:32 UTC
查看更新说明
iMessage Exporter 5.0.0: Speckled Clarkia contains the following fixes and improvements:
- New Features
- Contacts-based conversation merging
- Combine phone numbers and email addresses belonging to one person, including linked Contacts cards on macOS and iOS
- Merge conversations split across those addresses, including group chats
- Preserve separate group chats with different names unless Messages explicitly links them
- Skip ambiguous identity matches when an address belongs to multiple Contacts cards
- Allow
--contacts-path(-n) to override the Contacts database in encrypted and unencrypted iOS backups
- Contacts-based conversation merging
- Performance
- Read message bodies and edit histories with message rows instead of fetching them separately for each message
- Parse body data directly from query results, avoiding intermediate buffers in the main decoding path
- Replace the separate payload-presence query with a flag in the message query
- Bug Fixes
- Fix inflated poll vote counts when participants change selections or Messages repeats vote updates for #823
- Fix null values in archived app-message payloads and render links as plain URLs when preview metadata is absent or null for #805
- Preserve recovered body components and edit history when text recovery fails
- Keep attachments and handwriting from recovered deleted messages in their conversation’s attachment directory for #827
- Route messages from linked chat rows without participant records to their conversation instead of the orphaned transcript
- Fix incorrect contact matches caused by country-code collisions and iOS search-index phone fragments
- Reject unmatched conversation filters even when date filters are supplied
- Reject out-of-range handwriting dimensions and handle empty text-rendering canvases
- Enhancements
- Improve conversation naming and filtering
- Use one filename and attachment directory for every chat row in a merged conversation
- Choose consistent contact names and fallback addresses, honoring linked contacts’ preferred names
- List each participant once and improve long filename truncation and remaining-participant counts
- Match conversation filters against every Messages address belonging to a grouped participant
- Clarify diagnostic counts and report participants and conversations merged through Contacts
- Improve database and backup path errors for #829, #808, #647, #590, #493, and #359
- Distinguish missing paths, permission failures, invalid SQLite files, and databases without Messages data
- Suggest database and backup locations based on files found on disk
- Improve default home-directory resolution, including Windows support
- Improve conversation naming and filtering
- API Changes
- Breaking (migration guide)
- Decode message text, body components, and edit history during row loading; remove separate body-decoding calls
- Replace callback streaming and generic query/cache traits with prepared-statement iteration and concrete APIs
- Separate participant identity groups from stored addresses and use those groups for chat deduplication
- Return decoded timestamps in UTC and accept explicit timezones for date filtering and presentation
- Separate exported attachment paths and media types from database rows
- Revise diagnostic fields, error variants, and public module paths
- Ergonomic
- Re-export
chrono,plist, andrusqlitefromimessage_database
- Re-export
- Breaking (migration guide)
- Miscellaneous
- Exclude test fixtures from the published library package
- Recommend
cargo install --locked - Expand regression coverage, consolidate exporter tests, and enforce formatting in CI
- Update supported-version documentation
- Bump dependencies and build with latest
rustc
⚠️ Version 5.0 include
- New Features
- 4.3.0Shining Willow2026-09-15 · 2026-09-15 01:27 UTC
查看更新说明
iMessage Exporter 4.3.0: Shining Willow contains the following fixes and improvements:
- New Features
- macOS Golden Gate and iOS 27 Support
- Parse SMS filter categories, including allowed, junk, promotional, and transactional messages, for #790
- Preserve raw filter subcategory values for downstream crate consumers
- Parse attachment source attribution, including app name, bundle ID, and App Store ID, for #791
- Identify drawings created with the Messages drawing board
- Optional message-derived file timestamps for #785
- Add
--use-message-timesto stamp each transcript's creation time from its earliest rendered message and modification time from its latest - Set each new attachment file's creation time to its message date on macOS and Windows
- Leave directories and transcript files without messages unchanged
- Add
- macOS Golden Gate and iOS 27 Support
- Performance
- Resolve message result-set columns once per query instead of selecting an extraction path and rescanning column names for every row for #792
- Preserve narrow projections for current schemas and remove redundant joined columns from legacy queries
- Schema detection is now capability-based
- Bug Fixes
- Fix preflight attachment disk-space estimates ignoring conversation and date filters for #778
- Prevent a solo
-pinvocation that doesn't request diagnostics or exports from decrypting a database just to do nothing
- Enhancements
- Support reordered and omitted optional columns across Messages database schemas and custom message queries
- Tapbacks and tapback stickers render in chronological order
- Diagnostic output now shows detected database schema features
- Expose chat filtering status for #801
- API Changes
- Breaking
- Add
filter_actionandfilter_sub_actionfields toMessage Message::from_row()now deserializes by column name instead of assuming a fixed positional layout- Custom queries must preserve the required
rowid,guid,date,is_from_me,num_attachments, andnum_repliescolumn names
- Custom queries must preserve the required
- Query methods now take
&CapabilitiesMessage::from_guid,stream_rows,get_count,get_replies,get_votes,as_pollAttachment::from_message
- Add
- Ergonomic
- Add
FilterActionwith parsing, display, and filtered-category helpers - Add
Message::filter_action() - Add
AttachmentAttributionwith bundle ID, app name, App Store ID, and drawing-detection helpers - Add
Attachment::get_attribution() - Add
tables::capabilities::CapabilitiestypeCapabilities::determine(&Connection)probes a schema once- Query construction derives from the result
- Add
- Breaking
- Miscellaneous
- Reorganize message models into focused modules while preserving their public paths
- Update supported-version documentation
- Significant new test coverage
- Bump dependencies
- Build with latest
rustc
- New Features
- 4.2.0Stream Orchid2026-06-18 · 2026-06-18 22:57 UTC
查看更新说明
iMessage Exporter 4.2.0: Stream Orchid contains the following fixes and improvements:
- New Features
- Inline sticker rendering for #755 and #756
- Render Memoji, Genmoji, and custom stickers inline with surrounding message text in HTML exports
- Scale inline-only sticker and emoji messages like jumbomoji
- Resolve inline sticker attachments by file-transfer GUID instead of attachment row order
- Digital Touch rendering for #344
- Support taps, sketches, kisses, heartbeats, heartbreaks, fireballs, photos, and videos
- HTML exports now render static Digital Touch frames as embedded SVG on a black
4:5canvas - Photo Digital Touch messages render the photo backdrop with drawing overlays
- Video Digital Touch messages render as embedded video players
- TXT exports describe each effect with useful stroke, point, or beat metadata
- Business Chat messages for #769 and #770
- Render Quick Replies in HTML and TXT exports
- Render Interactive Forms, including requests and submitted responses
- Render List Pickers, including prompts and selected replies
- Expanded Data Detector support
- Parse structured currency amounts, postal addresses, package tracking numbers, flights, and unit/timezone conversions from
DDScannerResultpayloads - Preserve structured detector metadata for downstream crate consumers
- Parse structured currency amounts, postal addresses, package tracking numbers, flights, and unit/timezone conversions from
- Inline sticker rendering for #755 and #756
- Performance (≈+29%)
- Optimize blob reads and database connection settings
- Skip immediately discarded queries for tapbacks, poll votes, and poll updates
- Cache resolved chat filenames
- Increase base buffered-writer capacity
- Pre-size date formatting buffers
- Bug Fixes
- Fix multi-attachment and inline-sticker pairing by matching body ranges to attachment rows by GUID
- Preserve translated text, original text, and inline stickers in mixed HTML and TXT runs
- Render edited Memoji / Genmoji history as inline images
- Fix malformed empty-stroke handling in handwriting messages
- Fix handwriting SVG file writes
- Prevent Check In timestamp overflow
- Add overflow handling to message parsing paths
- Add plist UID recursion-limit handling
- Fix index references in event parsing errors
- Fix currency detection edge cases
- Fix Digital Touch alpha conversion for SVG/CSS colors
- Improve Digital Touch media kind matching in HTML exports
- Remove CSS
:hasselector usage for broader HTML viewer compatibility - Improve resolved-contact percentage calculation
- Correct busy-bar gating for attachment work
- Enhancements
- Refactor
AttachmentManagerinto focused planning, target-resolution, mode, and execution modules - Reuse existing attachment outputs when rerunning exports against the same destination
- Refactor temporary encrypted-backup database handling so cleanup happens after SQLite connections close
- Add table and column existence checks for diagnostics on older database schemas
- Centralize diagnostic count queries
- Centralize URL/rich-link metadata handling behind shared helper traits
- Centralize progress tracking logic
- Migrate
typedstreamparsing tocrabstep'sfoundationfeature - Reorganize text-effect parsing into focused animation, style, and detected-data modules
- Add dedicated Digital Touch models and SVG render pipeline
- Add Business Chat parsing and rendering models behind the shared balloon-provider flow
- Refactor
- API Changes
- Breaking
- Replace
BubbleComponent::TextandBubbleComponent::AttachmentwithBubbleComponent::Run(Vec<AttributedRange>) - Replace
TextAttributeswithAttributedRange- Use
AttributedRange::text(...),AttributedRange::attachment(...), orAttributedRange::inline_attachment(...) - Attachment ranges now carry
attachment: Option<AttachmentMeta>andemoji_image
- Use
- Move text-effect types into submodules:
- `m
- Replace
- Breaking
- New Features
- 4.1.0Chaparral Yucca2026-05-29 · 2026-05-29 03:12 UTC
查看更新说明
iMessage Exporter 4.1.0: Chaparral Yucca contains the following fixes and improvements:
- New Features
- Rendering Engine
- Migrate HTML and TXT exporters to an Askama-based template engine
- Hard cutover: previous string-builder code path is fully removed
- 20 HTML templates and 22 TXT templates created
- Per-format logic split between typed Rust view models and Askama template files
- Shared rendering primitives consolidated so export types consume identical message structures
- New view-model / driver layer is format-agnostic
- Migrate HTML and TXT exporters to an Askama-based template engine
- Interactive iOS backup decryption password input via #730 (contributed by @jmcp)
- Using an encrypted iOS backup without
-xnow prompts interactively -xstill supported for non-TTY contexts
- Using an encrypted iOS backup without
- Rendering Engine
- Bug Fixes
- Disable progress bar when run headless for #738
- Support both automatic TTY detection and manual suppression via
--no-progress
- Support both automatic TTY detection and manual suppression via
- Fix sticker attachments not incrementing the attachment index
- Fix double-indentation on replies in TXT output
- Fix SharePlay's embedded "Ended" line not receiving the per-line reply indent
- Fix several balloon spacing inconsistencies:
- Leading whitespace before
ldtextinfind_my/apple_pay - Trailing colon when
ldtextis absent - Stray whitespace when
app_nameis omitted
- Leading whitespace before
- Fix
format_urlrendering blank lines whenprimary/title/summaryare empty strings - URL messages with a missing payload row are now rendered through the standard URL renderer
- Normalize announcement wording across export types
- Fix broken sticker conversion on Windows
- Fix 1-indexed
ffmpegHEICS conversion assembly - Fix sticker offset reconstruction gaps
- Error logs no longer clobber the progress bar
- Disable progress bar when run headless for #738
- Enhancements
ffmpegprocessing warning now fires for animated stickers in addition to videos- Per-frame
ffmpegloop replaced with a singleffmpeginvocation that consumes both image sequences and appliesalphamergeacross them - Resolve self/recipient names through a single resolver so announcements and edits treat the local user identically
- File-not-found errors now identify the missing path and resolution mode
- Add context to edited message parse errors
- API Changes
-
Breaking
- Remove
Message::started_sharing_location()andMessage::stopped_sharing_location()in favor ofMessage::shared_location_kind() EditedEvent.textis nowString- Remove
Table::extract. UseTable::rowsorTable::rowinstead.
Multi-row iteration:
Single-row fetch:
- Remove
-
Ergonomic
- Add
StickerDecorationenum andAttachment::get_sticker_decoration()- Consolidates
get_sticker_source/get_sticker_source_application_name/get_sticker_effectdispatch into a single call returning a format-agnostic decoration
- Consolidates
- Add
impl Display for Expressive<'_> - Derive
Clone + CopyonBubbleEffect,ScreenEffect, andExpressive<'a> - Derive
DefaultonURLMessage<'a> - Unify the exporter's
MessageFormattertrait under a singleRuntimeErrorreturn typeformat_app,format_tapback, and `forma
- Add
-
- New Features
用户点评
登录用户的真实使用记录,可按版本和硬件筛选还没有人点评。第一个说出真实体验的人最有价值。
imessage-exporter
This crate provides both a library to interact with iMessage data as well as a binary that can perform some useful read-only operations using that data. The aim of this project is to provide the most comprehensive and accurate representation of iMessage data available.
This free and open-source software can:
- Save, export, backup, and archive iMessage data to open, portable formats
- Preserve multimedia content (images, videos, audio) from conversations
- Facilitate easy migration of message history between devices and platforms
- Run diagnostics on the iMessage database
- Give you full ownership and control over your communication history
- Support compliance with data retention policies or legal requirements
- Run on macOS, Linux, and Windows
Example Export

Binary
The imessage-exporter binary exports iMessage data to txt or html formats. It can also run diagnostics to find problems with the iMessage database.
Installation instructions for the binary are located here.
Library
The imessage_database library provides models that allow us to access iMessage information as native, cross-platform data structures.
Documentation for the library is located here.
Supported Features
Support for every iMessage feature as of macOS Golden Gate 27.2 (26B123) and iOS 27.2 (24B119):
- iMessage, RCS, SMS, and MMS
- Multi-part messages
- Replies/Threads
- Formatted text
- Attachments
- Expressives
- Tapbacks
- Stickers
- Apple Pay
- Group chats
- Digital Touch
- URL Previews
- Audio messages
- App Integrations
- Edited messages
- Business messages
- Handwritten messages
See more detail about supported features here.
Frequently Asked Questions
The FAQ document is located here.
Special Thanks
- All of my friends, for putting up with me sending them random messages to test things
- SQLiteFlow, the SQL viewer I used to explore and reverse engineer the iMessage database
- Xplist, an invaluable tool for reverse engineering the
payload_dataplist format - Compart, an amazing resource for looking up esoteric unicode details
- GNU Project and Archive.org, for hosting source code referenced to reverse engineer the
typedstreamformat