# Application warmup

## Overview

This article explains how the warmup process of your application is performed, which helps to deliver optimal performance. The warmup of your application is automatically performed in the following cases:

* during deployment
* when scaling out
* after unexpected restarts

The warmup mechanism sends a set of requests to the application, which would force it to generate different levels of application cache when building the responses, before it starts serving actual traffic.

> info **NOTE**: By default, the [Warmup service module](https://www.progress.com/documentation/sitefinity-cms/site-warmup) is disabled in Sitefinity Cloud considering the setup and configuration specifics of the platform.

## Warmup process

Sitefinity Cloud uses the standard IIS warmup feature. For more information, see Microsoft documentation » [Application Initialization](https://learn.microsoft.com/en-us/iis/configuration/system.webserver/applicationinitialization/).

* The `<applicationInitialization>` section in the
  `web.config` includes paths that are used for making requests to the application on
  start or restart.
* The requests are automatically done by the IIS.
* This way, after deployment, scale-out, or unexpected restarts, the application is prepared to handle actual traffic.

## Default behavior

The warmup is performed by the `CI.CD` pipeline and is done for both the Production and non-Production environments.

During deployment, the `CI.CD` pipeline gets the top 50 most viewed pages from *Application Insights* and includes them in the `<applicationInitialization>` section of the `web.config` file.

If you use multiple domains for a single application, the list of paths in the `web.config` section includes the respective hostnames as well.

## Customize the warmup behavior

You customize the warmup behavior by adding an `<applicationInitialization>` section to your `web.config` file. This will override the default behavior.

In this section, you can add the desired URLs. You must also include the `doAppInitAfterRestart` attribute and set it to `true`.

> info **NOTE**: You cannot include the same URL path twice in the `<applicationInitialization>` section, even if the hostname is different. For example, if you want to warmup the `/` path for two different domains, you can add a query string to differentiate them.

Use the following example:

```xml
<applicationInitialization doAppInitAfterRestart="true">
    <add initializationPage="/?hostName=first-domain.com" hostName="first-domain.com"/>
    <add initializationPage="/?hostName=second-domain.com" hostName="second-domain.com"/>
</applicationInitialization>


```

To customize the warmup URLs per environment, you can also use `web.config` transformation files.\
For more information, see [Manage the configurations](https://www.progress.com/documentation/sitefinity-cms/cloud/develop-and-deploy/manage-the-configurations).
