Date posted

17 Nov 2022

Read Time

Related Articles

Google Analytics 4

Flexible attribution modelling has arrived in Google Analytics 4

Google Analytics 4

What are segment overlap explorations in Google Analytics 4?

Google Analytics 4

What is data retention in Google Analytics 4?

Contrary to popular belief, Google Analytics does not keep your data forever. 

With so many websites across the world using Google Analytics, the sheer volume of data being stored and processed, for free, on Google’s servers is significant. 

It was inevitable, therefore, that control settings would be introduced so that Google can manage the delicate balance of data storage, processing and performance on their servers. This led to data retention control settings being introduced within the admin area of Universal Analytics and, subsequently, Google Analytics 4.

How can you use the data retention control settings?

Data retention control settings provide the ability to set the length of time before Google Analytics user and event level data is automatically deleted from Google’s servers. These control settings are often overlooked, and can have a detrimental impact on data analysis and collection if not configured correctly.

In Google Analytics 4, the data retention control settings work differently compared to Universal Analytics. It is important to ensure these control settings in Google Analytics 4 are configured correctly for optimal and effective use of your data.

Where do I find the data retention settings?

Within Google Analytics 4, navigate to Admin > Data Settings > Data Retention.

Here, you will find the options to modify your data retention settings. You have two options to configure: event data retention and reset user data on new activity.

User and event data retention

Event data retention

The event data retention option allows you to specify the length of time that Google Analytics 4 data is stored, before it is automatically deleted from Google’s servers.

Standard (i.e. non-enterprise) Google Analytics 4 users have two options to select, either two months or 14 months. Retention options are significantly reduced for standard Google Analytics 4 users, who were afforded retention options up to 50 months in the standard version of Universal Analytics.

Enterprise Google Analytics 4 users have a greater scope of options to select, either two months, 14 months, 26 months, 38 months or 50 months.

Important: When you first set-up a Google Analytics 4 property, the data retention setting is defaulted to two months for both standard and enterprise customers. Such a short duration on data retention seriously limits the use of data within some Google Analytics reports, which we will explain in more detail later on in this article. We recommend that you increase the retention settings to at least 14 months, to allow YOY data comparison.

The event data retention setting in Google Analytics 4 also works slightly differently to its predecessor in Universal Analytics. When changing the data retention setting in Universal Analytics, changes were not applied retroactively. Within Google Analytics 4, any changes to the event data retention applies to both future and historical data which provides far greater flexibility.

Reset data on new user activity

This setting is an on/off toggle which has a significant impact depending on the option that you select. By default the toggle is set to on.

By keeping the toggle set to on, the expiration date is reset to current time plus the retention period for each new event.

This can be best explained using an example. 

Let’s assume the data retention period remains at the default setting of two months, and that a user visits a website on the 1st, 15th and 31st October generating a page view event each time.

Event  Date event initiated Expiration date
Reset data on new activity = on
Expiration date
Reset data on new activity = off
page_view  1st October 1st December 1st December
page_view  15th October 15th December 1st December
page_view 31st October 31st December 1st December

As we can see from the above example, changing this setting from the default option will reduce the amount of time your data is kept before expiration. As such, we recommend keeping this setting toggled on.

Which reports are these settings applied to?

Important: Data retention settings are not applicable to all reports in Google Analytics 4.

However, in the following scenarios data retention settings do apply:

  • Adding segments to pre-built reports
  • Adding secondary dimensions to pre-built reports
  • Creating any custom reports via the exploration tool

In each of these instances, the pre-calculated tables cannot be used and the underlying data source needs to be used to retrieve the data.

Given the reduced volume of pre-built reports in Google Analytics 4, and the increased emphasis on using the explorations reports to create bespoke reports, there will be many instances whereby reporting is powered by underlying data and not pre-calculated tables. This makes the length of duration of your data retention settings critical in Google Analytics 4.

What can I do if I want retention longer than 14 months?

For the vast majority of Google Analytics 4 users, who will be on the standard version, the significantly reduced options when it comes to data retention will take some getting used to. 

It begs the question of ‘What options do I have if I want data retention to be longer than 14 months?’

Your option in this case will be to take advantage of the Google Analytics 4 and BigQuery integration. This integration, which is available to both standard and enterprise users of Google Analytics 4, offers a daily export of your Google Analytics 4 dataset into BigQuery providing you complete control over exactly what data you keep, and for how long. It also doubles up as creating a back-up of your Google Analytics 4 dataset that sits outside of the main interface.

Bear in mind that there are costs associated with BigQuery based on data querying and data storage once the free allowances have been exceeded (at the time of writing free allowances are a generous 1TB of querying per month and 10GB of active storage per month) and that you will need to become well versed with writing SQL to extract the data you need for your analysis.

So, how is data retention handled within Google Analytics 4?

With ever increasing volumes of Google Analytics data being stored and processed on Google servers, it was inevitable that data retention measures would be put in place by Google to achieve the optimal balance of data storage, processing and performance.

Here are the key points to be aware of in how data retention is handled within Google Analytics 4:

  • Event data retention is defaulted to two months in Google Analytics 4, but can be increased via the admin settings. Standard Google Analytics 4 users have a maximum duration of 14 months, and enterprise users 50 months.
  • When changing data retention duration in Google Analytics 4, the changes apply both to historical and future data. This is much improved compared to Universal Analytics, where retention duration changes were not applied retroactively.
  • Data retention does not apply to pre-built reports, as they are based on pre-calculated tables. For these reports, data will be available as far back as property creation.
  • The exception to the above is if you apply secondary dimensions or segments to a pre-built report. In these cases the report needs to use your underlying data and will be subject to the retention settings that are in place.
  • Data retention settings are applicable to any bespoke reports that are created via the explorations module in Google Analytics 4.
  • Consider taking advantage of the Google Analytics 4 and BigQuery integration. This will set-up a daily export of your Google Analytics 4 dataset into BigQuery, allowing you complete control over what data you keep and for how long. This also has an added advantage of providing you a back-up of your Google Analytics 4 data that sits outside of the interface.
  • Be mindful that querying and storing data in Google Analytics 4 can incur costs once the free allowances have been exceeded (at time of writing these are 1TB of querying per month and 10GB of active storage per month). Furthermore, experience of writing SQL queries will be required to extract the data from BigQuery ready for analysis.

If you have any questions around Google Analytics 4, from getting started to the different integrations, functionalities and features, our team are here to help!