Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I can't find any documentation on how postfix stores email. Where is it stored, and in what format? I'm using Ubuntu server 11

share|improve this question
up vote 16 down vote accepted

Probably /var/mail/[username] or the more traditional /var/spool/mail/[username]

The normal format, called "mbox", uses a line that starts with "From " to indicate the start of each message - this is one reason why many email clients will change "From " in the body of the message to ">From ". You can also configure it to use "maildir", in which /var/mail/[username] is a directory in which every email message is a file in that directory.

share|improve this answer
This is of course assuming that the user doesn't have procmail configured to do it for him instead. – Shadur Oct 26 '11 at 5:13
It's also assuming that they haven't installed cyrus-sasl which moves things around. We're trying to keep things simple. – Paul Tomblin Oct 26 '11 at 13:00

For outbound mail (you didn't specify, and inbound is answered elsewhere) it is in /var/spool/postfix. If you look there you will find all sorts of subdirectories.

share|improve this answer
I cannot find my outbound mails inthere on my debian machine. – simonpie May 6 '13 at 0:45
I cannot find my outbound mails in there on my debian machine. This directory is used but things there are store only trensiently. Alpine stores outbound emails in /home/[username]/mail/sent-mail for example. – simonpie May 6 '13 at 0:57
Postfix does not store outgoing mail permanently. Once it's off the system, it's no longer the responsibility of the MTA. If you need a permanent copy, Bcc: yourself, or use whatever your MUA offers (like you mention for Alpine). – tripleee Jun 11 '14 at 9:09
Yes, it's ephemeral. Take down your net connection and send an email. Then you'll see something queued up... – Aaron D. Marasco Feb 2 '15 at 1:20

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.