Blog/ Apple Mail & iCloud

Where Does Apple Mail Store Emails on a Mac?

Nafiul HasanNafiul Hasan· 12 min read
Apple Mail folder location on a Mac — the Library Mail folder open in Finder showing the versioned subfolder structure

The short answer

Apple Mail keeps all its message data inside ~/Library/Mail on your Mac. Inside sits a versioned subfolder — V10, V11, V12 — whose number increments with each major macOS release. To back it up safely, quit Mail first, then copy the entire Mail folder. The Envelope Index is the search database; damage to it causes missing messages and failed searches.

Apple Mail stores emails in ~/Library/Mail/V[n]/ — the version number changes each major macOS release. Find, back up, and manage that folder safely.

On this page
  1. 01The short answer: where Apple Mail keeps your messages
  2. 02Before you start
  3. 03How to navigate to the Apple Mail folder
  4. 04What each item inside the Mail folder does
  5. 05Which version folder matches your macOS
  6. 06What to do when Apple Mail cannot find your messages
  7. 07How to back up Apple Mail messages
  8. 08A different way to manage a growing inbox

The question of where Apple Mail stores emails on a Mac comes up at the worst moments: the hard drive is nearly full, you are migrating to a new Mac, or Mail is behaving strangely and you want to inspect the underlying database. The answer is not a single static path — Apple Mail keeps messages inside a numbered versioned subfolder that changes its name with each major macOS release. That one moving part is why most articles you find online cite a path that is one or two version numbers out of date.

This guide explains where to find the correct folder on whatever version of macOS you are running, what each file inside it does, and how to back up the entire data container without corrupting the search index that Mail depends on. It also covers what to do when that index fails — the most common cause of Mail showing wrong message counts or returning no results from search.

The short answer: where Apple Mail keeps your messages#

Apple Mail stores all its data — messages, attachments, and its search index — inside a folder at ~/Library/Mail on your Mac. The tilde represents your home directory, so for a user named Sarah the full path is /Users/sarah/Library/Mail.

Inside that Mail folder is a versioned subfolder whose name Apple increments with each major macOS release. On macOS Monterey it is typically V9; on Ventura, V10; on Sonoma, V11; and on Sequoia, V12. If you have upgraded through several macOS versions, you may see more than one numbered folder — Mail migrates messages into a new one on each upgrade and leaves the old folder behind. The active folder is always the highest-numbered one with a recent modification date.

Inside the versioned folder, each email account you have added to Mail gets its own subfolder named after its account identifier. Each account folder contains a hierarchy of mailbox bundles ending in .mbox. Individual messages live inside those bundles as .emlx files — one file per message.

The Envelope Index is a separate SQLite database at ~/Library/Mail/V[number]/MailData/Envelope Index that Apple Mail uses to power search. When this file becomes corrupted, Mail starts misbehaving in recognizable ways: searches return nothing, message counts are wrong, or the app runs slowly regardless of available memory.

Before you start#

Two things are worth knowing before you touch any files inside ~/Library/Mail.

First, the Library folder is hidden by default. Apple hides it to protect casual users from accidentally deleting system data. You can reveal it temporarily by holding the Option key while clicking the Go menu in Finder — the Library item appears only when Option is held. Alternatively, you can navigate directly to it using the Go to Folder command.

Second, POP accounts download messages to this folder permanently. IMAP accounts store messages on the server but cache them locally here. Deleting the local IMAP cache will not delete messages from the server, but it forces Mail to re-download everything on next launch. Messages stored only in On My Mac mailboxes exist nowhere else — they must be backed up explicitly or they are gone.

Quit Apple Mail before touching any files

Mail holds open file locks while it is running. Copying, moving, or deleting files inside ~/Library/Mail while Mail is active can corrupt the Envelope Index or leave message files in an inconsistent state. Use Command + Q to fully quit the app — closing the window is not enough.

How to navigate to the Apple Mail folder#

  1. 1

    Quit Apple Mail

    Press Command + Q with Mail in focus, or right-click the Mail icon in the Dock and choose Quit. Confirm the app is no longer running before proceeding — a solid dot beneath the Dock icon means it is still active.

  2. 2

    Open Finder and reveal the Library folder

    Hold down the Option key and click the Go menu in the menu bar. The Library item appears in the dropdown only while Option is held. Click it to open your user Library folder at /Users/yourname/Library/.

  3. 3

    Alternatively, use Go to Folder

    Press Command + Shift + G in Finder (or choose Go > Go to Folder from the menu bar), type ~/Library/Mail, and press Return. This works regardless of whether the Library folder is currently visible in the Finder sidebar.

  4. 4

    Open the Mail folder and identify the active version

    Inside the Mail folder, look for a subfolder whose name starts with V followed by a number — for example V10, V11, or V12. If more than one exists, the folder with the highest number and the most recent modification date is the one Mail is currently using.

  5. 5

    Open the versioned folder

    This is your Mail data container. Inside you will find one subfolder per email account, a MailData folder containing the Envelope Index and other metadata databases, and — depending on account type — an Attachments folder with locally cached files.

What each item inside the Mail folder does#

Once you can see inside the versioned folder, the contents break into a small number of meaningful items. Understanding each one matters for two practical reasons: it tells you what is safe to inspect, copy, or delete, and it tells you which files a complete backup must include.

ItemWhat it containsSafe to delete?
Account subfolders (e.g. [email protected])One per email account. Contains .mbox bundles with individual .emlx message files.No — deletes local copies. IMAP accounts re-download from server; POP data is unrecoverable.
MailData/Contains the Envelope Index, Subjects database, and other metadata files that power search and message counts.No — Mail can rebuild these files, but the process takes hours on a large mailbox.
Envelope Index (no file extension)SQLite database that indexes all messages for fast search. The most fragile file in the folder.No — rebuilding it is safe when it is damaged, but do not delete it otherwise.
Envelope Index-shm, Envelope Index-walShared memory and write-ahead log for the SQLite database. Present while Mail is running or after an unclean shutdown.Only if Mail is fully quit — safe to remove before a rebuild of the index.
Attachments/Local cache of downloaded email attachments.Conditionally — IMAP attachments can be re-fetched from the server; POP attachments may not be recoverable.
Signatures/HTML files for each email signature you have created in Mail.No — back these up separately if you have custom signatures you want to preserve.

Which version folder matches your macOS#

The version number inside ~/Library/Mail changes with each major macOS release. The table below shows recent versions as of mid-2026. If your Mac has been upgraded through several releases, you may have multiple version folders — only the highest-numbered one is active.

Apple does not publish an official list of these version numbers, and they do not always follow a predictable pattern across all upgrade paths. The safest approach is always to navigate to ~/Library/Mail and check what is actually there, rather than relying on a specific version number from any article — including this one.

macOS versionRelease yearMail data folder
Monterey (12)2021V9
Ventura (13)2022V10
Sonoma (14)2023V11
Sequoia (15)2024V12

What to do when Apple Mail cannot find your messages#

The most common symptom of a damaged Envelope Index is Mail showing zero unread messages when you know there are many, or search returning no results for terms you can see in the message list. In almost every case the messages themselves are still present as .emlx files on disk — it is the index that has failed, not the messages.

Mail's built-in rebuild process: quit Mail fully, then reopen it, hold the Option key, and click the Mailbox menu in the menu bar. A Rebuild option appears that does not show up without Option held. Click it. Mail reads each .emlx file on disk and reconstructs the Envelope Index from scratch. On a large mailbox this can take several hours; a progress indicator appears at the bottom of the message list.

If the rebuild does not resolve the issue and the affected account is IMAP, the fastest recovery is to remove the account from Mail settings and re-add it. Mail clears the local cache and re-downloads everything from the server. Any messages stored only in On My Mac mailboxes must be restored from a backup before you remove the account, or they will be lost permanently.

Disk space note: the Mail folder on a Mac used for several years with multiple active accounts can grow to tens of gigabytes. The largest single contributors are usually locally cached IMAP attachments and downloaded message bodies. The cleanest way to reclaim space is to remove an account through Mail settings and let Mail delete the local cache, rather than deleting raw files directly from the folder.

Diagram showing the Apple Mail data folder in two states: on the left, a corrupted Envelope Index causes empty search results and wrong message counts while the .emlx files remain intact on disk; on the right, after a rebuild the index correctly points to those same files and full message visibility is restored.
The .emlx message files are almost never lost. A rebuild re-indexes files that are already present on disk.

How to back up Apple Mail messages#

A complete backup of your Apple Mail data means copying the entire Mail folder — not just the message files, but also the MailData subfolder and its Envelope Index. Without the index a backup is still useful (Mail can rebuild it on import), but with the index intact the restore is faster and requires no waiting.

  1. 1

    Quit Apple Mail

    Use Command + Q to fully quit the app. The Envelope Index must not be held open by any process during the copy, or the backup may capture the file mid-write.

  2. 2

    Navigate to ~/Library in Finder

    Hold Option and click Go in the menu bar, then click Library. Or use Go > Go to Folder and type ~/Library to jump there directly.

  3. 3

    Copy the Mail folder to your backup destination

    Right-click the Mail folder and choose Copy. Paste it to an external drive, a network location, or a cloud storage folder that syncs to disk. The copy can take several minutes if the folder is large.

  4. 4

    Verify the copy is complete

    Open the copied folder and confirm the versioned subfolder is present and that its MailData folder contains an Envelope Index file. A backup missing MailData is incomplete, though the messages themselves are still recoverable.

  5. 5

    To restore on a new Mac: copy in reverse

    Quit Mail on the new Mac, navigate to ~/Library, and replace the Mail folder with your backup copy. Open Mail and it should display your accounts and messages. You may need to re-enter account passwords — credentials are stored in Keychain, not in the Mail folder.

Export individual mailboxes for targeted archiving

Mail also supports exporting individual mailboxes as .mbox archives: select a mailbox in the sidebar, choose File > Export Mailbox, and pick a destination. An exported .mbox file can be imported back into Mail on another Mac or opened by most standard email clients. This is useful for archiving old mail without copying the entire data folder.

A different way to manage a growing inbox#

Most people end up inside the Apple Mail Library folder because the inbox has accumulated years of unmanaged volume — thousands of messages cached locally, attachments downloaded in bulk, and no systematic triage keeping noise separate from things that need action. The storage and index problems are symptoms of that underlying pattern.

AI Emaily is an email client we build that approaches inbox management differently. It connects to your mail accounts and applies AI triage, drafting, and follow-up automation as mail arrives — so the inbox is organized from the start rather than after years of accumulation. Because processing happens server-side, there is no local Envelope Index to maintain or Library folder growing in the background from unprocessed mail.

If you are rethinking whether Apple Mail still fits your workflow, a 7-day free trial at app.aiemaily.com/pricing lets you run AI Emaily against your real inbox before committing to anything. Autonomous triage, voice drafting, and follow-up handling are all included during the trial.

Frequently asked

Nafiul Hasan

Written by

Nafiul Hasan

Nafiul Hasan is an entrepreneur and AI automation system builder with 10+ years of experience turning messy, manual workflows into reliable automated systems. He designs and ships AI enterprise solutions end-to-end — the agent logic, the data plumbing, and the product people actually use — and founded AI Emaily to give busy professionals their attention back. He writes here from the builder's seat: what works, what breaks, and how to put AI to work without giving up control.

EntrepreneurAI Automation System BuilderAI EnthusiastBuilds AI Enterprise Solutions10+ years experience
More from Nafiul
Ready when you are

Stop managing your inbox manually

AI Emaily is an AI-native email client with autonomous triage, voice drafting, and follow-up automation — built so your inbox stays organized as mail arrives. 7-day free trial, no commitment.

  • 7-day free trial
  • Cancel anytime
  • Every provider