How to switch mailboxes in Mutt?

You can write a macro and bind it to a key, or key sequence. For example, in my muttrc I include this line:

macro index \Cs  "<change-folder> =JWR/INBOX.Sent<enter>"  "go to Sent Items"

It takes me to my Sent items with Ctrls.

You can determine the correct name of the relevant maildir folder by bringing up the prompt with c and then hitting ? for the list.


mutt sidebar sample screenshot

The arch wiki has a good section on enabling and using the TUI sidebar. You can either set it visible all the time:

set sidebar_visible = yes

Or bind sidebar-toggle-visible to a key. sidebar-prev and sidebar-next are used to switch the folder selection, and sidebar-open opens the selected folder.


On my system, I wanted to go back to the INBOX and had to use the following, Otherwise if I did C? and went to another folder, I couldn't get back to the inbox.

macro index <home>  "<change-folder> =INBOX"<enter>

Tags:

Mutt