The mailbox format that stores all messages in a single file is mbox.
Mbox is a family of Unix-origin mailbox formats in which messages are concatenated sequentially in one plain-text file. Each message is separated from the next by a special “From ” line, often called the From_ line, followed by the sender information. This arrangement makes an mbox file easy to export, archive, and move between systems.
Its single-file design also creates drawbacks. Mail software must lock the file when reading or changing it, because simultaneous delivery and deletion can corrupt data or cause inconsistent results. Large mailboxes can also be slower to update than formats that use one file per message.
Mbox is often contrasted with Maildir, which stores each message as a separate file in directory structures. The name is not one perfectly uniform standard: mboxo, mboxrd, mboxcl, and mboxcl2 are historically important variants with different rules for identifying message boundaries.