Skip to content

Mutt


Encrypt Messages

Press `P` followed by `e` for encrypt (`s` for sign as well)

Email-related settings:

Setting Example Explanation
set from example@example.com Set the sender's email address.
set from_display John Doe Set the sender's display name.
set use_envelope_from yes Use the sender's email address for the envelope.
set use_from yes Use the sender's email address as "From" in messages.
set allow_8bit yes Allow 8-bit characters in email messages.
set charset utf-8 Set the character set for emails.
set send_charset iso-8859-1 Set the character set for sent email messages.
set realname John Doe Set the user's real name for outgoing emails.
set envelope_from yes Use the envelope sender address for outgoing emails.
set imap_user john@example.com Set the IMAP user (email address).
set imap_pass myIMAPpassword Set the password for the IMAP server.
set folder ~/Mail Set the path to the email folder.
set smtp_url smtp://smtp.example.com Set the SMTP server URL for outgoing emails.
set smtp_pass mySMTPpassword Set the password for the SMTP server.

Email Signature and Encryption:

Setting Example Explanation
set signature_file ~/.signature Set the path to the signature file.
set pgp_auto_decode yes Automatically decode PGP-encrypted messages.
set pgp_autosign yes Automatically sign outgoing messages with PGP.
set pgp_autosmime yes Automatically encrypt outgoing messages with PGP/SMIME.
set pgp_replyencrypt yes Encrypt replies with PGP when the recipient has a PGP key.
set pgp_replysign yes Sign replies with PGP.
set pgp_replysignencrypted yes Sign encrypted replies with PGP.
set pgp_use_gpgme yes Use the GPGME library for PGP functionality.
set pgp_verify_sig yes Verify PGP signatures for incoming messages.

Email Handling:

Setting Example Explanation
set copy "=drafts" Copy a message to the specified folder.
set mbox_type Maildir Set the type of mbox for email folders.
set move "=archive" Move messages to the specified folder.
set new "400" Set the time (in seconds) a message is "new".
set postpone "=later" Move messages to be sent later to the specified folder.
set record "=archive" Copy messages to the specified folder upon sending.
set sort date-received Sort email by date received.
set sort_aux from Additional sorting key after sender.
set sort_browser yes Enable sorting in browser mode.
set sort_re yes Re-sort when replying/forwarding.
set sort_threads yes Sort email threads.
set strict_threads yes Use strict email thread grouping.
set pipe_decode yes Decode piped messages.
set delete yes Allow deletion of messages.
set markers "=flagged" Use flags to mark messages.
set quote_regexp "^(>[[:space:]]?)" Set the pattern to quote previous messages.
unset reply_self Disable replying to oneself.

Email Lists and Filtering:

Setting Example Explanation
set hdr_order "From: To: Subject: Date:" Set the order of header fields to display.
set ignore "*.spam" Ignore messages matching the specified pattern.
set alias_file "~/.mutt/aliases" Set the path to the alias file for email lists.
set search_headers yes Search specific header fields when searching for email.
set text_flowed yes Set if text flowed is supported in email messages.

PGP/SMIME-related settings:

PGP Settings:

Setting Example Explanation
set pgp_sign_as "John Doe john@example.com" Set the PGP key to use for signing.
set pgp_timeout 3600 Set the timeout (in seconds) for PGP operations.
set pgp_verify_key "0xDEADBEEF" Set the PGP key used for key verification.
set pgp_mime_good_signers yes Allow PGP signatures from known senders.

S/MIME Settings:

Setting Example Explanation
set smime_default_key "john@example.com" Set the default S/MIME key for encryption.
set smime_get_cert_command "smime_getcert" Set the command to fetch S/MIME certificates.
set smime_get_crl_command "smime_getcrl" Set the command to fetch S/MIME CRL.
set smime_replyencrypt always Encrypt replies with S/MIME on every occasion.

General Functions:

Setting Example Explanation
set editor "vim" Set text editor for composing emails.
set pager_index_lines 10 Set the number of lines to display per screen in index mode.
set pager_stop yes Stop at page boundaries during scrolling.
set visual "vim" Set text editor for viewing email messages.
set wait_key yes Wait for keypress to continue.
set quit "yes: " Set a prompt message upon quitting.
set print "lpr" Set the command for printing email messages.
set resolve yes Automatically resolve names to email addresses.
set include "~/.mutt/muttrc_extra" Set the path to an additional configuration file to include.
set query_command "contacts_query %s" Set the command to query contacts.
set macro "z" "l=10" Set macro definitions for quick commands.

Formatting and Presentation:

Setting Example Explanation
set status_format "[%r%m messages. %f/%t]" Set the format for the status line.
set header_cache "~/.mutt/cache/headers" Set the path to the cache file for headers.
set message_cachedir "~/.mutt/cache/bodies" Set the path to the directory where messages are cached.
set mailcap_sanitize "text/html; lynx -dump -stdin" Set the command for displaying HTML email as text.
set forward_format "Fwd: %s" Set the format for forwarded email subjects.
set charset-hook "utf-8 :utf8:noconv" Set character conversion settings for email.
set header_format "From: %f%(%n%)nSubject: %snDate: %dn" Set the format for displaying header fields.

Miscellaneous:

Setting Example Explanation
set abort_noattach yes Abort sending if no attachments are included.
set pager_filter "spamassassin" Set the filter command to use when viewing email messages.
set status_on_top yes Show the status line on top of the email list.
set status_chars "[!`~]" Set characters indicating different status levels.
set pipe_separator "----ENCRYPTED MESSAGE----" Set the separator for piped messages.
set pipe_decode_cmd "gpg –decrypt" Set the command for decoding piped messages.
set escape "H" Set the character to return to the main menu.
set escape_timeout 10 Set the timeout (in seconds) to return to the main menu.
set from_valias yes Enable virtual alias for sending address.
set edit_headers "From Cc Bcc" Set which header fields to edit when sending.
set markers "yes" Enable markers for replies and forwards.
set noignore yes Disable ignoring email lists.
set imap_authenticators "GSSAPI" Set the authentication mechanism for IMAP server.
set url_view_command "firefox" Set the command to open URLs.
set action "quit =ask-yes" Set alternative actions for quitting.

General Settings:

Setting Example Explanation
set sleep_time 0 Time (in seconds) to wait between IMAP operations.
set timeout 3 Time (in seconds) to wait for the IMAP server.
set beep yes Play a sound when a new message is received.
set beep_new yes Play a sound only for new messages.
set tilde Allow "~" as a special character in IMAP search strings.
set pager_index_lines 5 Number of lines to display in index mode.
set pager_context 5 Number of lines to display in surrounding context.
set menu_scroll Use menu for scrolling in email messages.
set reverse_name Use reverse name format in email addresses.
set quit ask-yes Ask for confirmation upon quitting.
set delete ask-yes Ask for confirmation before deleting emails.
set print ask-yes Ask for confirmation before printing emails.

Editing Settings:

Setting Example Explanation
set editor vim -c 'set syntax=mail ft=mail enc=utf-8' Set the text editor for composing emails.
set indent_str "> " Set the character sequence for quoting in replies.
unset edit_headers Disable editing of header fields when sending.

Search and Filtering Settings:

Setting Example Explanation
set thorough_search Enable thorough search in all email messages.
set simple_search ~f %s | ~C %s | ~s %s Set simple search pattern for quick email search.
set quote_regexp "^(>[[:space:]]?)" Set the pattern for identifying quoted sections.
set markers no Disable markers for replies and forwards.
unset confirmappend Disable confirmation for attaching files.
unset mark_old Disable marking of old messages.

Viewing and Formatting Settings:

Setting Example Explanation
set attribution * %n <%a> [%{%Y-%m-%d %H:%M:%S %Z}]:n Set the format for displaying email attributes.
set visual vim Set the text editor for viewing email messages.
set status_on_top Show the status line on top of the email list.
set nouse_domain Disable the use of the domain in email addresses.
set pager_stop yes Stop at page boundaries during scrolling.