Skip to content

MBOX viewer and MBOX to PDF converter

Browse multi-gigabyte MBOX archives without uploading mail, inspect messages safely with remote tracking blocked, and save PDFs or EMLs.

Drop a Google Takeout or Thunderbird .mbox file here

Also opens zipped .mbox archives. Files are indexed in streaming 4 MiB chunks without uploading.

Loads a 3-message sample archive with attachments and blocked tracking pixel.

How to use MBOX viewer & PDF

  1. Load an MBOX, MBX, or zipped archive. Click Choose MBOX file to open your mailbox export, or click Load sample MBOX to inspect the built-in three-message mailbox.
  2. Filter Google Takeout emails by query, Gmail label, or attachments. Narrow indexed messages using Search mailbox messages, X-Gmail-Labels filter pills, or the Has attachments checkbox.
  3. Preview HTML or plain text locally. Select any message row to compare the sanitized Formatted pane against raw Plain text without firing tracking images.
  4. Configure PDF layout and message selection. Pick A4 or US Letter page size, toggle Add PDF bookmarks per message or List attachment names, and adjust checkboxes using Toggle all.
  5. Export selected emails, attachments, or metadata. Click Export N selected as PDF, Export EMLs (.zip), Extract attachments (.zip), or Download index CSV.

Your files are processed on this device and never uploaded. They stay private, and there's nothing to delete afterwards.

How does this MBOX viewer open multi-gigabyte mail archives?

To open an MBOX file on macOS, Windows, or Linux without installing Thunderbird, this browser-based MBOX viewer scans archives inside a Comlink Web Worker using 4 MiB byte-offset chunks (STREAM_CHUNK_SIZE). Because it stores byte slices and probes only 24 KB per header (HEADER_SCAN_LIMIT), multi-gigabyte Google Takeout dumps become searchable locally without network transfers.

Rather than unpacking every email attachment up front, lazy indexing keeps full message bodies unread on disk until selected. You can test takeout-sample.mbox immediately with Load sample MBOX, which contains three messages, a text attachment, and a stripped tracking pixel, or reset the workspace anytime with Change MBOX.

Under the RFC 4155 mailbox format specification, concatenated mailboxes split along unindented From boundaries while single .eml files fall back cleanly to byte offset 0. For a single standalone .eml file without an archive container, use EML to PDF export without uploading raw mail.

Parsing Thunderbird MBOX boundaries and mboxrd From lines

MBOX files store mail sequentially without a central directory, so delimiter parsing controls archive integrity. Inside the worker, isFromSeparatorLine checks unindented From lines measuring 10 to 511 bytes containing a sender and ctime or ISO timestamp, ignoring indented body prose.

RFC 4155 separator detection and mboxrd unescaping

Unix writers prepend > to body lines starting with From to prevent false message splits. As noted in the Library of Congress MBOX preservation notes, reversible mboxrd escaping adds one > to any line matching ^>(>*From ).

Clicking a message invokes unescapeMboxrdMessage after the \r?\n\r?\n header divider, stripping one leading > cleanly while keeping headers unchanged. Proprietary Microsoft Outlook .msg containers use binary OLE storage instead of Unix text delimiters and need a separate reader to open Outlook MSG container files locally.

MIME headers, Gmail labels, and ZIP safety limits

The 24 KB probe extracts Subject, From, To, Date, Message-ID, X-Gmail-Labels, and a 140-character snippet, decoding encoded tokens per the RFC 2047 MIME header encoding standard and RFC 2231 filename continuations.

Extracted X-Gmail-Labels populate All labels filter pills alongside Search mailbox messages and Has attachments. Zipped Takeout inputs unpacked via extractZipArchive ignore __MACOSX/ and .DS_Store noise while enforcing 5,000 entries, 250 MB single-file, and 500 MB cumulative uncompressed caps before scanning nested .mbox or .mbx files.

Sanitizing email HTML and blocking remote tracking pixels

Archived newsletters and unknown correspondence often embed scripts or hidden 1x1 pixels pointing to external servers. Selecting any message filters markup through sanitizeEmailHtml before rendering the Formatted view, while Plain text exposes raw decoded text cleanly.

Stripping unsafe script tags and HTTP tracking pixels

To protect local inspection, sanitizeEmailHtml strips script, style, head, title, iframe, object, embed, applet, noscript, svg, math, template, and xml elements entirely. Every external HTTP and HTTPS <img> node is dropped so remote tracking URLs never trigger requests; images carrying alt attributes leave readable [Image: alt] placeholders.

Privacy audit check: Even when an archived message embeds live tracker image tags, sanitizeEmailHtml removes every external URL before touching the DOM. Load takeout-sample.mbox via Load sample MBOX to verify zero outbound image traffic inside DevTools.

Resolving local inline cid images without network calls

Corporate signatures and inline diagrams often live inside MIME multipart/related sections tied to Content-ID attributes. Following the RFC 2392 Content-ID URI scheme, matched cid: images resolve strictly from local message attachments.

The HTML sanitizer rewrites matched cid: artwork and allowed base64 data:image/ URLs (png, jpeg, jpg, gif, webp) into local data URIs while preserving safe target="_blank" and rel="noopener noreferrer" link attributes.

Exporting selected emails to PDF, EML ZIPs, and CSV indexes

After filtering rows with search terms or label pills, use Toggle all, individual row checkboxes, or preview buttons (Save and Save message attachments ZIP) to export selected records cleanly.

Output action Generated filename suffix Payload format and schema Primary downstream use
Export N selected as PDF -selected.pdf Combined PDF, 10.5 pt sans, 48 pt margins Printable discovery packets and archival reports
Export EMLs (.zip) -eml.zip 0001-<64-char-slug>.eml RFC 5322 files Re-importing mail into Thunderbird or Apple Mail
Extract attachments (.zip) -attachments.zip Sanitized filenames prefixed by index Collecting attached PDFs, invoices, and images
Download index CSV -index.csv UTF-8 BOM CSV across 9 metadata columns Spreadsheet sorting and discovery inventories
Save message attachments ZIP message-<num>-attachments.zip Attachments scoped to active preview Pulling attached files from one single message

Bookmarked PDF layout and non-Latin font substitution

Running Export N selected as PDF writes an A4 or US Letter PDF with 10.5 pt sans body text, 48 pt margins, optional Add PDF bookmarks per message outlines, and List attachment names summaries. Characters outside standard WinAnsi Latin fonts are folded or replaced with ?, reporting exact replacement counts; compiled PDFs can pass straight to a bulk PDF text extraction pass.

EML ZIP numbering, attachment bundles, and CSV index columns

Choosing Export EMLs (.zip) runs unescapeMboxrdMessage per checked row and writes sequentially numbered files up to 64 sanitized slug characters. Selecting Download index CSV prepends a UTF-8 BOM (\uFEFF) across nine columns (#, Subject, From, To, Date, Labels, Has Attachments, Size (Bytes), Message-ID) for spreadsheet sorting.

When should you inspect exported headers from an MBOX mailbox?

Exporting a suspicious email through Export EMLs (.zip) or Save reveals complete unescaped RFC 5322 transport headers (Received, Authentication-Results, DKIM-Signature, and Return-Path). When diagnosing spoofed senders, phishing campaigns, or SMTP relay bottlenecks inside Takeout archives, load exported .eml headers directly into Email Header Analyzer for chronological hop timing, TLS verification, and DMARC alignment checks.

  • Investigating delivery latency: Export target .eml slices to audit chronological SMTP relay timestamps, encrypted TLS transport, and clock skew across mail servers.
  • Re-importing selective folders: Filter X-Gmail-Labels pills before calling Export EMLs (.zip) so migrated archives carry only chosen categories across mail clients.
  • Preserving discovery trails: Pair -selected.pdf packets with -index.csv spreadsheets so legal reviewers retain unique Message-ID identifiers alongside exported timestamps and attachment flags.
  • Resetting large browser sessions: Click Change MBOX between exports to cancel active worker tasks and release indexed byte-offset tables from browser memory.

Questions

How can I open a large Google Takeout MBOX file without uploading it?

Drop the extracted .mbox file or zipped Takeout download into Choose MBOX file. A Comlink Web Worker scans byte offsets in 4 MiB chunks and reads only the first 24 KB of each message header during indexing, keeping multi-gigabyte exports responsive locally without remote transfers.

Does this MBOX viewer load remote tracking pixels or external images?

No. Before HTML renders in the Formatted pane, sanitizeEmailHtml strips external HTTP and HTTPS image sources so remote marketing pixels never fire requests. Inline images attached via cid references convert to local data URLs, and blocked external images with alt text display bracketed labels.

How does mboxrd unescaping fix >From lines in email bodies?

Unix mbox writers quote body lines starting with From by adding a leading greater-than sign to avoid breaking message boundaries. When opening or exporting a message, unescapeMboxrdMessage detects the header blank line and removes one leading > from matching body lines while leaving headers intact.

Can I convert selected MBOX emails into one bookmarked PDF?

Yes. Check specific rows or click Toggle all, select A4 or US Letter dimensions, enable Add PDF bookmarks per message, and click Export N selected as PDF. Each email begins on a clean header block accompanied by PDF outline bookmarks and optional attachment listings.

What differs between Export EMLs (.zip) and Extract attachments (.zip)?

Export EMLs (.zip) writes each checked message as an unescaped RFC 5322 .eml file numbered from 0001 onward up to 64 slug characters. Extract attachments (.zip) skips message text and packages only attached files and inline assets across checked emails into one archive.

Why are non-Latin characters sometimes replaced with question marks in PDFs?

The client PDF generator renders text using standard 10.5 pt Latin fonts without external font files. Characters outside WinAnsi coverage are folded where supported or replaced with question marks, and the summary reports the exact replaced count.

Updated