GUIDEHow to convert .partial.emlx files to .eml with their attachments

All I have left of my email is the Mail folder from a Time Machine backup. How do I turn those .emlx and .partial.emlx files into mail I can open?

Apple Mail keeps every message as a numbered .emlx file. Messages with attachments are often .partial.emlx files: the message without its attachments, which sit in a separate Attachments folder. Drop the folder here: EmlxRescue writes one standard .mbox per mailbox, or a ZIP of .eml files, with every attachment put back inside its message.

Apple: “You can export mailboxes in mbox format.” (Apple Support, “Import or export mailboxes in Mail on Mac”). That export is a menu command of Mail on a Mac. With only the files from a backup, there is no Export command to choose.

  • Nothing uploaded: your mail stays on your device
  • Attachments of .partial.emlx files put back in
  • Works in a browser on Windows, Mac or Linux

At a glance

What EmlxRescue does and doesn’t do

  • Works withApple Mail’s .emlx and .partial.emlx files, in the folders Mail keeps them in (Name.mbox … Messages, with Attachments next to it), or as loose files. A whole Mail folder, one account or one mailbox.
  • ProducesOne .mbox file per mailbox, or a ZIP with one .eml per message in a folder per mailbox. Attachments of partial messages are put back inside the message. Plus report.csv.
  • Runs onAny current browser: Windows, Mac, Linux. Desktop recommended. Nothing to install.
  • FreeReading everything, the full report, and converting the first 25 messages of each mailbox.
  • FullUSD 9 one-time ($9). Every message of every mailbox. No subscription.
  • PrivacyYour files are read in your browser. Nothing is uploaded.
  • Doesn’tConvert to PST. Recover attachments whose Attachments folder is not in your copy. Read .mbox or .olm files. Import into Gmail for you.
  • Tested withThe sample set published by the open-source partial-emlx-converter project: a plain .emlx comes out byte-for-byte identical to that tool’s reference .eml; the rebuilt .partial.emlx has the line count and boundary positions that project’s own test expects, and its parts decode to the same content as the reference .eml; every base64 attachment put back matches the original file (SHA-256), and text attachments match except for their final line break; every .mbox is re-read with Python’s standard mailbox module.
Reads the message files written by
  • Apple Mail on the Mac
2 outputs

one .mbox per mailbox, or a ZIP of .eml files

mbox or eml
SHA-256

every base64 attachment put back in our tests equals the original file

What we checked
25

messages of each mailbox converted free, with the full report

Try it
$9

once, every message of every mailbox, no subscription

Pricing

The problem

The mail is all there. Nothing opens it.

The Mac died, or was sold, or the account was closed. What is left is a copy of the Mail folder: thousands of numbered files in folders with long names.

One file per message

Each message is a file such as 1498.emlx: a line with the size of the message, the message, and a list of properties added by Mail. Other mail programs do not take that file as it is.

The attachments are somewhere else

A .partial.emlx has the message but not its attachments. Those are loose files in Attachments, under the number of the message and the number of the part.

Export needs a running Mail

Apple: “You can export mailboxes in mbox format.” That is a command in Mail’s Mailbox menu. A folder of files has no menu.

How it works

Three steps. No account, no upload.

  1. Step 1

    Get the Mail folder onto this computer

    From your backup, copy the Mail folder (inside Library, in your user folder) to a disk this computer can open. Where the files are

  2. Step 2

    Drop the folder here

    EmlxRescue reads every message on your computer and lists the mailboxes, the partial messages, and the attachments it found or could not find.

  3. Step 3

    Download mbox or eml

    One .mbox per mailbox, all mailboxes in a ZIP, or a ZIP of .eml files. The attachments are back inside the messages. Which one to pick

Apple’s help page, on finding the folder on a Mac: “To get to the Mail folder on a Mac, click the desktop to make sure you’re in the Finder, press and hold the Option key, choose Go > Library, then select the Mail folder.” (Apple Support, “Import or export mailboxes in Mail on Mac”).

Convert a folder

Add your Apple Mail folder

Everything runs on this page. Your mail never leaves your device.

Drop your Mail folder here

The whole folder, one account, or one .mbox folder: any folder that holds both Messages and Attachments. Nothing is uploaded.

Reads .emlx and .partial.emlx files of Apple Mail. The files are only read, never changed. With “Choose folder” your browser may ask you to confirm that the page can read the folder: the files are read on this device and not sent anywhere.

Free: reading everything, the full report, and converting the first 25 messages of each mailbox. Unlock every message for $9.

Inside the files

A size, the message, Mail’s notes. And the attachments in a folder of their own.

EmlxRescue cuts the message out of each file, finds the parts that Mail emptied, and fills them again from the Attachments folder.

  • The first lineThe number of bytes of the message. The message is exactly that many bytes; the .eml is those bytes.
  • The emptied partIn a .partial.emlx, an attachment keeps its headers, gets a line X-Apple-Content-Length, and loses its content.
  • The fileAttachments/1498/3/Report.pdf: message 1498, part 3. It goes back into that part as base64, in lines of 76 characters.
1498.partial.emlx
44126                    bytes of the message
Return-Path: …           the message, as received
--boundary
Content-Disposition: attachment;
  filename=Report.pdf
X-Apple-Content-Length: 76502

--boundary--
<plist>                   date-received, flags
the folder
Lists.mbox/  …  /Data/1/
  Messages/1498.partial.emlx
  Attachments/1498/3/Report.pdf

What you get

Standard files, with the attachments inside.

Not a new format to get stuck in: mbox and eml, the two plain ways to keep email in files.

One .mbox per mailbox

Each mailbox becomes one file with all its messages, named after the mailbox. Nested mailboxes keep their path, such as Parent/Child.

Or a ZIP of .eml files

One .eml per message, in a folder per mailbox, named with the number Mail gave the message.

Attachments put back

Every part that Mail emptied is filled again from its file in Attachments, encoded as the part’s headers say.

A list before you download

Per mailbox: messages, partial messages, attachments found and missing, messages marked deleted. Click a message to see its headers and text.

A report of what is missing

report.csv has a line for every attachment of every partial message, and for every file that could not be read, with the reason.

Stays on your device

Email is private. The files are read and converted in your browser and nothing is sent anywhere.

What we checked

Real Apple Mail files, compared with a reference.

Only what we ran: the sample set published by the open-source partial-emlx-converter project (MIT), whose conversion ours follows, and a mailbox folder from the public hoover-testdata set.

WhatWhat EmlxRescue doesWhat we checked
A plain .emlxThe .eml is the message, untouchedThe result is identical, byte for byte, to the reference .eml of partial-emlx-converter (2,945 bytes)
A .partial.emlxRebuilds the message with its four attachments2,169 lines, with the 11 boundary lines at the positions that project’s own test expects; its text parts and its four attachments decode to the same content as in the project’s reference .eml
Attachments put backbase64 or quoted-printable, as the part says13 attachments in 7 partial messages, decoded from the rebuilt messages: the 9 base64 ones have the same SHA-256 as the file in Attachments; the 4 text files written as quoted-printable are the same except for the file’s final line break, which MIME counts as part of the boundary. Among them a file name split over two header lines, a name with an umlaut, a Japanese name, a name with no extension, and a part with no name at all
Mail’s folder layoutNames the mailbox, finds the attachmentsA real mailbox folder, lists.mbox/…/Data/1/Messages with Attachments/1498/3: the mailbox is named “lists” and the PDF is put back, same SHA-256
A missing attachmentConverts the message, reports the fileA partial message whose Attachments folder is absent: converted, and its four attachments are listed in the report by name. Nothing is made up
.mboxOne per mailbox, mboxrdRe-read with Python’s standard mailbox module: same number of messages, same subjects, same attachment names and SHA-256. A line starting with “From ” inside a message does not split it
ZIP of .emlA folder per mailboxPasses unzip -t; the files unpacked are the converted messages
Files that are not .emlxRefuses, and says whyA text file, a cut .emlx and an empty one: each is listed with its reason and nothing is written for it

Pricing

Free to read and try. $9 once for everything.

Start free

Free

$0

Reading everything, the full report, and converting the first 25 messages of each mailbox.

Convert my mail
  • Every mailbox and message listed
  • Attachments found and missing, counted
  • The complete report.csv
  • The first 25 messages of each mailbox, as .mbox or .eml
  • No account

ONE-TIME

EmlxRescue Full

$9 USD

one-time · every message · every mailbox

Unlock everything, $9
  • Every message of every mailbox
  • One .mbox per mailbox, or all in a ZIP
  • A ZIP of .eml files
  • Attachments put back in every partial message
  • No subscription
Secure checkout by Stripe. The full version unlocks in the browser you pay from. Questions: support@cedanolabs.org.

FAQ

Questions about converting Apple Mail .emlx files

Want the long version? Read the guide.

Read the guide
How do I convert .emlx files to .eml or mbox?

Open EmlxRescue in a browser and drop the folder that holds your Apple Mail files: the whole Mail folder from your backup, one account, or one mailbox folder. EmlxRescue reads every .emlx and .partial.emlx file, shows the mailboxes and messages it found, and writes one standard .mbox file per mailbox, or a ZIP with one .eml file per message. Nothing is uploaded: the files are read by the page, on your computer.

What is a .partial.emlx file?

It is a message that Apple Mail stored without its attachments. Inside the file, the part of each attachment has its headers and a line that starts with X-Apple-Content-Length, and no content. The content is a normal file in a folder named Attachments, next to the Messages folder: Attachments, then the number of the message, then the number of the part, then the file. A .partial.emlx on its own is a message with empty attachments.

How does EmlxRescue put the attachments back?

For each empty part it looks in Attachments for the folder of that message and that part, takes the file named in the part’s headers (or the only file in that folder when the headers give no name), encodes it the way the part says (base64 in lines of 76 characters, or quoted-printable), writes it into the part and removes the X-Apple-Content-Length line. In our tests, every base64 attachment put back was identical to the original file (we decoded the part and compared SHA-256 checksums); text attachments written as quoted-printable were identical except for the final line break of the file, which the MIME format counts as part of the boundary.

Which folder should I drop?

Any folder that contains both Messages and Attachments: the whole Mail folder, the folder of one account, or one folder whose name ends in .mbox. The mailbox name is taken from the folders ending in .mbox on the way to each message. If you drop only a Messages folder, or loose .emlx files, the messages are still converted, but the attachments of partial messages cannot be found; the report lists each one with the folder where it was expected.

Where is the Mail folder?

Apple’s help page says: “To get to the Mail folder on a Mac, click the desktop to make sure you’re in the Finder, press and hold the Option key, choose Go > Library, then select the Mail folder.” In a copy of your user folder it is the same place: the Library folder, then Mail. EmlxRescue does not read a backup disk by itself: it starts from the Mail folder, once that folder is on a disk your computer can open.

Does it work on Windows?

It is a web page, so there is nothing to install and the same code runs in a browser on Windows, Mac or Linux. You need the Mail folder on a disk that your computer can open. A desktop browser is recommended, because choosing or dropping a whole folder is a desktop feature. We ran our browser checks in Chrome on a Mac.

Should I download mbox or eml?

Both hold the same messages. An .mbox file is one file with every message of a mailbox, one after another; Apple’s help page says: “Mail can import email messages that have been exported in mbox format from other email apps”. An .eml file is one message; the ZIP has a folder per mailbox with one .eml per message, named with Mail’s message number. Which of the two your mail program takes is described in that program’s own help.

Can Apple Mail import the result?

EmlxRescue writes mbox files, the format Apple names in its help page: “Mail can import email messages that have been exported in mbox format from other email apps” and, for the import, “If you’re importing messages from a Windows or UNIX computer, select “Files in mbox format,” then locate the folder containing the files.” The same page also says that Mail on a Mac can import “a folder in the ~/Library/Mail/ folder on another Mac” directly, so with a working Mac you may not need a converter at all.

Why can’t I just export the mailboxes from Mail?

You can, if you have a Mac where Mail still opens those mailboxes. Apple’s help page says: “You can export mailboxes in mbox format.” and describes it as a menu command: “Select one or more mailboxes, then choose Mailbox > Export Mailbox.” With only the files from a backup there is no Mail window and no Export command: what you have is a folder of .emlx files, and those have to be converted.

What happens when an attachment is missing?

The message is still converted, with that attachment empty, and nothing is made up to fill it. The screen shows how many attachments are missing in each mailbox, and report.csv has one line for each: the mailbox, the message, the part, the file name the message asked for and the folder where it was expected. EmlxRescue cannot recover an attachment whose Attachments folder is not in your copy.

What about messages I had deleted?

Apple Mail keeps a set of flags after each message, and one of them marks a message as deleted. EmlxRescue shows how many messages of each mailbox carry that mark, and has a checkbox, “Skip messages marked as deleted”, that leaves them out of the files it writes.

Are my messages changed?

A plain .emlx is not: its .eml is exactly the bytes Apple Mail stored. In our tests it was identical, byte for byte, to the .eml of the open-source reference tool. In a partial message only the parts whose content was kept outside are rebuilt: the content goes back in, the X-Apple-Content-Length line goes away, and a part that was marked 7bit or 8bit is written as quoted-printable, as the reference tool does. In an .mbox, line ends become LF and a “>” goes before any line that starts with “From ”, which is how the mbox format keeps messages apart.

How many messages can it handle?

It works through the messages one at a time and never holds the whole mail store in memory: each message is read, converted and added to the output, which the browser may keep on disk. A ZIP is closed and a new one started at 60,000 files or 2 GB. What we ran is the sample set described on this page.

What is in report.csv?

One line for every attachment of every partial message, saying whether it was put back or is missing, with the mailbox, the message number, the file, the part, the attachment name and its size. It also lists every file that could not be read as .emlx, with the reason, and the messages left out because they are marked as deleted when you ticked that box. The report is complete in the free version.

Is my mail uploaded anywhere?

No. The files are read and converted by JavaScript on this page, on your device. There is no upload step and no account, and the code that handles your files makes no network request; our test checks that. Besides the files of the site itself, the site makes requests for cookieless page analytics and, if you buy the full version, for the payment check, which sends a payment ID and never a file or a message.

Does it convert to PST, or read .mbox or .olm files?

No. EmlxRescue reads Apple Mail’s .emlx and .partial.emlx files and writes .mbox and .eml. It does not write PST files, does not read .mbox or .olm files, and does not import anything into Gmail or any other account for you.

How is EmlxRescue different from partial-emlx-converter?

partial-emlx-converter is a free, open-source command-line tool (MIT license) by Philipp Katz. Its page says it is installed with Homebrew or npm, converts a folder of .emlx files to .eml files, and can import them into an IMAP account. EmlxRescue runs as a web page with nothing to install, also writes .mbox files with the mailbox names, and gives a report of missing attachments. Our conversion follows that tool, and we used its published sample files to check ours.

What files does a mailbox folder hold?

In the sample we checked, a mailbox is a folder whose name ends in .mbox. Inside it, under a folder with a long identifier and a folder named Data, are numbered folders, each with a Messages folder that holds the .emlx and .partial.emlx files, and an Attachments folder next to it. Each .emlx starts with a line that gives the size of the message, then the message itself, then a short list of properties written by Mail, such as the date it was received and its flags.

How does the $9 full version work?

Free gives you the reading of your whole folder, the full report, and the conversion of the first 25 messages of each mailbox, so you can check the result before paying. The full version is a single $9 payment, with no subscription and no account: every message of every mailbox. It unlocks in the browser you pay from.

Is this an Apple product?

No. EmlxRescue is an independent tool by Cedano Labs LLC. Not affiliated with Apple.

Get your mail back into files you can use.

Drop your Mail folder, see what is in it, and download it as mbox or eml. Free: reading everything, the full report, and converting the first 25 messages of each mailbox.