IMAP folder separator for Dovecot and Mutt

— door Evert Mouw

This is a short technical howto post. I couldn’t easily find this information on the webs, especially the neomutt error messages related to this subject, so I store this on my blog for my future self and for others.

Folder Separator

Dovecot uses the dot (.) as separator by default for Maildir and IMAP folders; Courier also uses the dot. Instead of a dot, one can also use a forward slash (/) or something else. The forward slash is very common and you might prefer it.

Open for editing: /etc/dovecot/conf.d/10-mail.conf

Under namespace inbox {, set:

Don’t forget a systemctl restart dovecot and you’re good to go.


I sometimes use Mutt to read my mail from the CLI. For folder subscriptions, I use:

Also I use a save-hook, which is an extra feature of neomutt compared to mutt:

Note the forward slashes to indicate a yearly subfolder. If Dovecot is using its default setting, then you have to change replace those slashes to dots; or you can change your Dovecot configuration. If you don’t do this, then you will get error messages such as:

imap_copy_messages [a0021 NO [CANNOT] Invalid mailbox name: Name must not have ‘/’ characters

[CANNOT] Invalid mailbox name: Name must not have ‘/’ characters

neomutt screenshot

Wees de eerste om te reageren

Geef een antwoord

Het e-mailadres wordt niet gepubliceerd. Vereiste velden zijn gemarkeerd met *

Deze website gebruikt Akismet om spam te verminderen. Bekijk hoe je reactie-gegevens worden verwerkt.