---
title: Configuring web analytics
related:
  - https://docs.kentico.com/13/on-line-marketing-features/managing-your-on-line-marketing-features/web-analytics.md
---

> 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).

Web analytics provide a way to measure and later analyze key metrics of your website such as visits, page views, traffic sources and more. The web analytics are built into Xperience and you can access the data directly in the administration interface.

To be able to work with metrics in the **Web analytics** application, you need to have the permissions for the [Web analytics](https://docs.kentico.com/13/on-line-marketing-features/configuring-and-customizing-your-on-line-marketing-features/configuring-on-line-marketing-permissions.md#web-analytics) module.

First, you need to enable web analytics:

- [Enable web analytics](https://docs.kentico.com/13/on-line-marketing-features/configuring-and-customizing-your-on-line-marketing-features/configuring-web-analytics/enabling-web-analytics.md)

In order to correctly log incoming traffic from search engines, you need to configure individual search engines in the system:

- [Manage search engines for web analytics](https://docs.kentico.com/13/on-line-marketing-features/configuring-and-customizing-your-on-line-marketing-features/configuring-web-analytics/managing-search-engines-for-web-analytics.md)

Logging of web analytics is anonymous and does not store personal data of your site's visitors. However, if you need to ensure extremely strict data protection compliance, you can customize the system and make logging of web analytics depend on the visitor's consent or another condition:

- [Log web analytics based on consent](https://docs.kentico.com/13/configuring-xperience/data-protection/gdpr-compliance/logging-web-analytics-based-on-consent.md)

Additionally, you can use the web analytics API to add tracking of custom actions as web analytics:

- [Add custom web analytics](https://docs.kentico.com/13/on-line-marketing-features/configuring-and-customizing-your-on-line-marketing-features/configuring-web-analytics/adding-custom-web-analytics.md)

You can also configure the system to automatically delete old web analytics data that is no longer needed:

- [Set up automatic web analytics data cleanup](https://docs.kentico.com/13/on-line-marketing-features/configuring-and-customizing-your-on-line-marketing-features/configuring-web-analytics/setting-up-automatic-web-analytics-data-cleanup.md)

## How web analytics work

After you set up and enable web analytics, the system performs the tracking on the side of the live site application using JavaScript and logging endpoints.

When a tracked event (such as a page view) occurs, a record is logged in the application's memory. The system periodically processes the analytics data from the memory and saves it into the database as a batch operation. By default, analytics data is processed every 10 seconds. If you wish to adjust the processing interval to optimize your site's memory or database performance, add the **CMSWebAnalyticsProcessingInterval** key into the _appSettings_ section of your **live site** application's _web.config_ file.

```html

<add key="CMSWebAnalyticsProcessingInterval" value="30" />

```

The logged analytics data is then loaded from the database and presented in the administration interface using reports (defined through the [Reporting](https://docs.kentico.com/13/configuring-xperience/working-with-system-reports.md) application).
