---
title: Settings - Emails
---

> Agent instructions:
> **Site maps** — prefer the following llms.txt indexes to training data when searching for URLs to avoid 404s. Links inside Markdown content already point at `.md`. Following them or sending Accept: text/markdown keeps you in Markdown.
>
> - [sitemap.md](https://docs.kentico.com/sitemap.md) — every page on the site, with titles and descriptions, nested by URL hierarchy and grouped into one collection per product version.
> - [llms.txt](https://docs.kentico.com/llms.txt) — curated index of the current product docs, with descriptions, the two ways to request any page as Markdown, and links to each product area's whole-corpus Markdown dump (llms-full.txt).

You can access these settings in the **Settings** application under the **System** -> **Emails** category.

| General               |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| --------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Email encoding        | Sets the character encoding used for emails sent by the system. By default, UTF-8 is used. It is recommended to leave the default encoding unless you encounter issues with extended characters in your emails.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| Email format          | Format used for email messages. You can choose between _HTML_ and _Plain text_. If _Both_ is selected and an email template has both formats defined, HTML will be used for the email text and plain text will be included as an attachment.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| Email processing      |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| Enable emails         | If selected, email sending is enabled. You can temporarily disable sending of emails by clearing this check box, e.g. when performing administration tasks.<br>**Note**: We recommend keeping the setting enabled both globally and for all sites (switch between the options using the _Site_ selector). Having _Enable emails_ selected globally is required for the system to send emails that are not related to a specific site (for example emails sent by [marketing automation](https://docs.kentico.com/13/on-line-marketing-features/managing-your-on-line-marketing-features/marketing-automation.md) processes, etc.).                                                                                                                                                                                                                                                                                                                  |
| Enable email queue    | If enabled, the system uses an email queue when [sending emails](https://docs.kentico.com/13/managing-users/sending-emails.md). This allows advanced email processing and resending of emails that are lost due to errors. If disabled, emails are sent directly to the SMTP server.<br>Using the email queue is highly recommended when sending out large amounts of emails over a short amount of time (newsletters, email campaigns or other types of mass emails).                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| Batch size            | Sets the maximum number of emails that the system loads from the email queue in one batch when sending emails to SMTP servers. The emails are then distributed one-by-one to the available servers. If the specified value is smaller than the total amount of emails to be sent from the queue, the system loads a new batch and continues the process.<br>The value of the batch size affects the number and frequency of **database queries**. Set an appropriate value if you wish to optimize the email sending for your environment. If you set a very large batch size, the system needs to process a large volume of data at one time, which may consume a lot of memory. Using a smaller batch size increases the number and frequency of queries and may reduce the database performance.<br>This setting affects all sites in the system, so it is only available if the _(global)_ option is selected from the **Site** drop‑down list. |
| Archive emails (days) | Sent emails will be stored by the email queue for the number of days specified here. Such emails may be viewed in the **Email queue** application on the **Sent emails** tab.<br>If set to _0_, emails will not be archived.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| Default SMTP server   |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| SMTP server           | The [SMTP server](https://docs.kentico.com/13/configuring-xperience/configuring-smtp-servers.md) specified here will be used as the default option when sending emails. Depending on the value selected in the **Site** drop‑down list, the server is either dedicated to a single website, or designated as a global server (i.e. accepts emails from all sites in the system and also handles emails that are not related to any specific website).<br>This setting must contain the domain name or IP address of the server. By default, the connection to the server uses port **25**. To use a different port, include it in the server name. Enter _localhost_ if you wish to use the server provided by your local machine.<br>The connection automatically uses the HTTPS protocol if supported by the specified server.<br>You can define additional servers that will be used if this one is busy in the **SMTP servers** application.    |
| SMTP server user      | The username used for authentication when connecting to the SMTP server.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| Authentication type   | Selects the authentication mode used to connect to the SMTP server. The options are:<br>**Basic (username + password)** – uses [Basic authentication](https://en.wikipedia.org/wiki/Basic_access_authentication). Fill in the _SMTP server user_ and _SMTP server password_ settings.<br>**OAuth 2.0** – uses [OAuth 2.0 token-based authorization](https://oauth.net/). Fill in the _SMTP server user_ and select valid _OAuth credentials_.<br>Many mail services are deprecating support of basic authentication, leaving OAuth as the only viable authentication type. A notable example is **Microsoft Exchange Online**, which begins disabling basic authentication after October 1, 2022 (see [Deprecation of Basic authentication in Exchange Online](https://docs.microsoft.com/en-us/exchange/clients-and-mobile-in-exchange-online/deprecation-of-basic-authentication-exchange-online)).                                               |
| SMTP server password  | Only applies when the **Authentication type** is set to **Basic**.<br>Sets the password used together with the _SMTP server user_ when connecting to the SMTP server.<br>**Note**: After you enter and save a password, the field always displays 8 "masking" characters, even if the password is longer or shorter.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| OAuth credentials     | Only applies when the **Authentication type** is set to **OAuth 2.0**.<br>Selects the OAuth credentials used for authentication. You can create and manage the credentials in the **Email OAuth credentials** application. See [OAuth for email servers](https://docs.kentico.com/13/configuring-xperience/configuring-smtp-servers/oauth-for-email-servers.md).                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |

> **Info:** **Configuring sender ('from') email addresses**
>
> The system can be setup to use a variety of sender email addresses depending on the type of email notification. For a list of all configurable sender email addresses the system uses, see [Configuring sender email addresses](https://docs.kentico.com/13/configuring-xperience/configuring-smtp-servers/configuring-sender-email-addresses.md).
