| folder "callsign" | location configuration in muttrc | use feature or not | purpose |
| "inbox" | $spoolfile | always | This is the startup folder assumed to contain all new email that arrives for you. |
| "mbox" or "received" | $mbox | $move | If you want to save (move) mails out of the inbox which you've read instead of deleting them right on (or cluttering up your inbox). |
| "sent" | $record | $copy | Sometimes it's good to keep a copy of sent out messages in case you need to resend them or verify discussions. |
| "postponed" | $postponed | $postpone | When you begin a new email but then decide to continue later, you don't have to discard everything to start over next time. Mutt can postpone your work for later completion. |
| "personal folders" | -- | -- | If you get a lot of mail, it's better to have several folders to keep messages separate for different uses (by topic, sender, recipient, subject). However, you use them by specifying the pathname each time, there is no mutt-internal management for those. Make up your mind about a folder structure before they get overloaded (bad overview & performance for too big folders). |
The "inbox" is provided by the system at a specific place. Default location is the $MAIL shell variable. Unless mutt is compiled to assume "inbox" in your $HOME dir, it will probably be something like "/var/spool/mail/USER".
All other folders can be located anywhere you can write to. However, the recommended default for them is to reside in a common subdir in your $HOME (like "~/Mail").
in muttrc: set record="$HOME/Mail/sent"; set mbox="$HOME/Mail/mbox"; set postponed="$HOME/Mail/postponed" => set folder="$HOME/Mail"; set record="+sent"; set mbox="+mbox"; set postponed="+postponed"Note: do not end "folder" path with a "/", because mutt automatically inserts one when you use "=" or "+". An extra one would break some functionality because of "//".
This easy access works for your personal folders in "$folder", too (like "+girlfriend" or "+sexmail"). It pays off when you use it in many more places in the config and interactively, like when you have many personal folders.
IMPORTANT Note: "+" & "=" are replaced with the expanded value of $folder at the time used with "set" (or hook). There is no dynamic link between them, so if you change $folder afterwards, then the "set" defined var (or hook-pattern) keeps its static value as defined before. Typically you set "$folder" first and all its dependencies after that, this means: the order matters. For advanced setups where you work with several different "$folder" values it can be useful to change it after you used it for some relative assignments. But there should always be some desired value before you use it the first time.
| refers to | typical place | mutt-var | shortcut |
| "inbox" | /var/spool/mail/USER | $spoolfile | "!" |
| $HOME dir | /home/user | no-mutt var | "~" or "$HOME" |
| folders dir | /home/user/mail | $folder | "+" or "=" |
| "mbox" | /home/user/mail/received | $mbox | ">" |
| "sent" | /home/user/mail/sent | $record | "<" |
| unfinished | /home/user/mail/postponed | $postponed | "+postponed" |
| personal | /home/user/mail/personal | "+personal" | |
| repeat the last for all your personal folders | |||
| last visited | varies | "-" or "!!" | |
| default folder for alias | varies | "@alias" | |
| currently open folder (*) | varies | "^" | |
Note: not all those vars are set by default, or maybe point to "untypical" places. Make sure you set them all as you want them!
The syntax for paths to remote folders is:
imap[s]://[user[:pw]@]imapserver[:port]/path pop[s]://[user[:pw]@]popserver[:port]/ (no path, POP can handle only 1 mailbox)Note: the "user", "password" and "port" parts are optional. imaps and pops are SSL-encrypted variants of imap and pop. More about IMAP & POP access configuration later.
"$folder" works for IMAP, too:
in muttrc: set folder="imaps://user@server.dom"to be used in UI for "change folder" cmd:
in mutt UI: c+sent<enter>
See also /Actions about Macros + TAB-completion.
It's recommended (although not required) to use the same format as the MDA, which places the new incoming emails into your "inbox".
If you can't change the MDA-format but prefer to use some other with mutt, just do so: mutt autodetects the mailbox formats when reading them.
When you create new folders, mutt will use the format specified in $mbox_type
(you have to create them all yourself, except "inbox", which should be provided by the system).
For now without further reasons, let's stick with MBOX format, the simple "classic".
Please be aware of confusion by OverloadedNames!