When I start Mutt, the default mailbox is whatever is in the $MAIL environment variable.

How can I startup Mutt, pointing to a different mailbox rather than $MAIL, or better still, how can I change the current mailbox from within Mutt?

I have a clue as to using a .muttrc file. Is there an example of a .muttrc which can open multiple inboxes?

1 Answer 1


What I do is set the MAIL environment variable to point to my mailbox. That way the setting applies to other programs (e.g. shells that show “you have new mail”). But you can do it from .muttrc as well:

set spoolfile = "/path/to/mailbox"

To start mutt showing a different mailbox as a one-off, run mutt -f /alternate/mailbox. Within mutt, type c to change to a different mailbox. After c, you can type the path to the mailbox, or you can use one of the shortcuts (see “Mailbox shortcuts” in the manual) such as ! to refer to spoolfile (or $MAIL) and =foo to refer to $folder/foo where $folder is defined in your .muttrc as

set spool = "/path/to/directory/containing/mailboxes"

If receive mail in several mailboxes and would like mutt to tell you when you receive mail in any of them, look up “Monitoring incoming mail” in the manual; basically you need to add this to your .muttrc:

mailboxes "/mailbox/to/watch" "/other/mailbox/to/watch"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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