1. The database
Your Mac keeps every message in ~/Library/Messages/chat.db. In Finder press ⌘ ⇧ G, paste that folder path, then drop chat.db and chat.db-wal together on the start page. The -wal file holds the newest messages; without it the last few days can be missing.
Only messages that are on this Mac are included. If older conversations are on your iPhone but not here, turn on Messages in iCloud on both devices (Messages > Settings > iMessage on the Mac) and let it sync first.
2. Names
The database only has phone numbers and emails. To show names, export your contacts: open Contacts, press ⌘ A, choose File > Export > Export vCard, then click Add names and pick that .vcf file. Local and international forms of the same number are matched. Names live in this tab only.
3. Photos and videos
Attachments are stored in ~/Library/Messages/Attachments. Click Show photos, press ⌘ ⇧ G in the folder dialog, paste that path and choose the folder. The browser may word it as an upload; nothing is sent anywhere, and files are only read when they scroll into view or when you export with "Embed photos" on.
4. Exporting
Open a conversation and pick a format at the top right. HTML is a single self-contained file that opens in any browser. PDF opens your print dialog with a clean layout: choose "Save as PDF" there. TXT, CSV and JSON are for archives, spreadsheets and other tools. Tapbacks, replies, group senders, edits, send effects and recently deleted messages are included in every format.
Court layout switches PDF and HTML to an ink-friendly record: full date and time, sender name and number on every message, read and delivered times written out. Page numbers are not included because the browser's print engine cannot add them; if you need numbered pages, print the PDF through a tool that adds headers and footers.
Export all in the top bar saves every conversation at once: a ZIP with one file per conversation, or one combined CSV with a conversation column for spreadsheets and e-discovery tools.
Filter narrows a conversation by date range, text and sender. Exports and stats follow the filter, so what you see is what you save.
5. iPhone backups
No Mac Messages history? A Finder or iTunes backup of an iPhone or iPad contains the same database. Click Open a backup folder on the start page and pick the backup folder itself; the messages database and attachments are located automatically via the backup's own index. Encrypted backups cannot be read: make a backup with "Encrypt local backup" unticked first.
Even an unfinished backup (a folder holding a Snapshot subfolder but no Manifest.db index) usually opens: the messages database is found by its known file name, and attachments that never finished copying simply show as file chips.
Privacy
Everything happens inside this browser tab. The page cannot make network requests other than loading itself, and closing the tab removes every trace. When you pick a folder, your browser asks to "upload" it: that is its fixed wording for granting read access, not a transfer. The demo database is fictional.