.\" Generated by scdoc 1.11.5 .\" Complete documentation for this program is not available as a GNU info page .ie \n(.g .ds Aq \(aq .el .ds Aq ' .nh .ad l .\" Begin generated content: .TH "AERC\-IMAP" "5" "2026\-09\-07" .PP .SH NAME .PP aerc\-imap \- IMAP configuration for \fBaerc\fR(1) .PP .SH SYNOPSIS .PP aerc implements the IMAP protocol as specified by RFC 3501, with the following IMAP extensions: .PP .PD 0 .IP \(bu 4 IDLE (RFC 2177) .IP \(bu 4 SORT (RFC 5256) .IP \(bu 4 THREAD (RFC 5256) .IP \(bu 4 LIST\-STATUS (RFC 5819) .IP \(bu 4 X\-GM\-EXT\-1 (Gmail) .PD .PP .SH CONFIGURATION .PP Basic IMAP configuration may be done interactively with the \fB:new\-account\fR command.\& .PP In \fIaccounts.\&conf\fR (see \fBaerc\-accounts\fR(5)), the following IMAP\-specific options are available: .PP \fBsource\fR = \fI\fR://\fI\fR[\fI:\fR]\fI@\fR[\fI:\fR]\fI?\&\fR[\fI\fR] .RS 4 Remember that all fields must be URL encoded.\& The \fI@\fR symbol, when URL encoded, is \fI%40\fR.\& .PP Possible values of \fI\fR are: .PP \fIimap\fR .RS 4 IMAP with STARTTLS .PP .RE \fIimap+insecure\fR .RS 4 IMAP without STARTTLS .PP .RE \fIimaps\fR .RS 4 IMAP with TLS/SSL .PP .RE \fIimaps+insecure\fR .RS 4 IMAP with TLS/SSL, skipping certificate verification .PP .RE \fIimaps+login\fR .RS 4 IMAP with TLS/SSL using the LOGIN authentication mechanism.\& This is used as a fallback when PLAIN authentication is not available.\& Most users should not need to specify this explicitly.\& .PP .RE \fIimaps+oauthbearer\fR .RS 4 IMAP with TLS/SSL using OAUTHBEARER Authentication .PP \fI\fR: .PP If specified and a \fItoken_endpoint\fR is provided, the configured password is used as a refresh token to obtain an access token.\& If \fItoken_endpoint\fR is omitted, refresh token exchange is skipped, and the password acts like an access token instead.\& .PP .PD 0 .IP \(bu 4 \fItoken_endpoint\fR (optional) .IP \(bu 4 \fIclient_id\fR (optional) .IP \(bu 4 \fIclient_secret\fR (optional) .IP \(bu 4 \fIscope\fR (optional) .PD .PP Example: .RS 4 imaps+oauthbearer://.\&.\&.\&?\&token_endpoint=https://.\&.\&.\&&client_id= .PP .RE .RE \fIimaps+xoauth2\fR .RS 4 IMAP with TLS/SSL using XOAUTH2 Authentication.\& Parameters are the same as OAUTHBEARER.\& .PP .RE .RE \fBsource\-cred\-cmd\fR = \fI\fR .RS 4 Specifies the command to run to get the password for the IMAP account.\& This command will be run using \fIsh \-c command\fR.\& If a password is specified in the \fBsource\fR option, the password will take precedence over this command.\& .PP Example: .RS 4 source\-cred\-cmd = pass hostname/username .PP .RE .RE \fBconnection\-timeout\fR = \fI .RS 4 Maximum delay to establish a connection to the IMAP server.\& See https://pkg.\&go.\&dev/time#ParseDuration.\& .PP Default: \fI90s\fR .PP .RE \fBkeepalive\-period\fR = \fI\fR .RS 4 The interval between the last data packet sent (simple ACKs are not considered data) and the first keepalive probe.\& After the connection is marked to need keepalive, this counter is not used any further.\& See https://pkg.\&go.\&dev/time#ParseDuration.\& .PP By default, the system tcp socket settings are used.\& .PP .RE \fBkeepalive\-probes\fR = \fI\fR .RS 4 The number of unacknowledged probes to send before considering the connection dead and notifying the application layer.\& .PP By default, the system tcp socket settings are used.\& If keepalive\-period is specified, this option defaults to 3 probes.\& .PP This option is only supported on linux.\& On other platforms, it will be ignored.\& .PP .RE \fBkeepalive\-interval\fR = \fI\fR .RS 4 The interval between subsequential keepalive probes, regardless of what the connection has exchanged in the meantime.\& Fractional seconds are truncated.\& .PP By default, the system tcp socket settings are used.\& If \fBkeepalive\-period\fR is specified, this option defaults to \fI3s\fR.\& .PP This option is only supported on linux.\& On other platforms, it will be ignored.\& .PP .RE \fBcheck\-mail\-include\fR = \fI\fR .RS 4 Specifies the comma separated list of folders to include when checking for new mail with \fB:check\-mail\fR.\& Names prefixed with \fI\(ti\fR are interpreted as regular expressions.\& This setting is ignored if your IMAP server supports the LIST\-STATUS command, in which case all folders will be checked.\& .PP By default, all folders are included.\& .PP .RE \fBcheck\-mail\-exclude\fR = \fI\fR .RS 4 Specifies the comma separated list of folders to exclude when checking for new mail with \fB:check\-mail\fR.\& Names prefixed with \fI\(ti\fR are interpreted as regular expressions.\& This setting is ignored if your IMAP server supports the LIST\-STATUS command, in which case all folders will be checked.\& Note that this overrides anything from \fBcheck\-mail\-include\fR.\& .PP By default, no folders are excluded.\& .PP .RE \fBcache\-headers\fR = \fItrue\fR|\fIfalse\fR .RS 4 If set to \fItrue\fR, headers will be cached.\& The cached headers will be stored in \fI$XDG_CACHE_HOME/aerc\fR, which defaults to \fI\(ti/.\&cache/aerc\fR.\& .PP Default: \fIfalse\fR .PP .RE \fBcache\-max\-age\fR = \fI\fR .RS 4 Defines the maximum age of cached files.\& Note: the longest unit of time \fBcache\-max\-age\fR can be specified in is hours.\& Set to \fI0\fR to disable cleaning the cache .PP Default: \fI720h\fR (30 days) .PP .RE \fBidle\-timeout\fR = \fI\fR .RS 4 The length of time the client will wait for the server to send any final update before the IDLE is closed.\& .PP Default: \fI10s\fR .PP .RE \fBidle\-debounce\fR = \fI\fR .RS 4 Specifies the length of time from the last client command until the idler starts.\& .PP Default: \fI10ms\fR .PP .RE \fBexpunge\-policy\fR = \fIauto\fR|\fIlow\-to\-high\fR|\fIstable\fR .RS 4 Specifies the deletion policy used when deleting multiple messages in one shot.\& \fIauto\fR attempts to automatically detect it, and will be correct most of the times.\& \fIlow\-to\-high\fR specifies that the server deletes messages in increasing sequence number order (this is what GMail and FastMail do, and is correctly handled by the automatic detection).\& \fIstable\fR specifies that the server does not mutate the sequence numbers it received (this is what Dovecot and WorkMail do, and is \fBnot\fR reliably automatically detected).\& .PP Default: \fIauto\fR .PP .RE \fBdebug\-log\-path\fR = \fI\fR .RS 4 Specifies the path where to store low\-level IMAP debug logs (this can be useful to debug interactions between aerc and IMAP servers).\& If this path is writable, aerc will create and log to one file per account, called `imap_debug_ACCOUNTNAME.\&log`.\& .PP By default, low\-level IMAP debug logs are not generated.\& .PP .RE .SH SEE ALSO .PP \fBaerc\fR(1) \fBaerc\-accounts\fR(5) .PP .SH AUTHORS .PP Originally created by Drew DeVault and maintained by Robin Jarry who is assisted by other open source contributors.\& For more information about aerc development, see \fIhttps://sr.\&ht/\(tirjarry/aerc/\fR.\&