Skip to main content

GOV.UK GA4 (BigQuery export)

We export our GOV.UK Google Analytics data and store it in Google BigQuery to enable more detailed analysis and the use of this data in other tools.

A flattened dataset is created from the data on the live site which contains most, but not all, of the same fields. The flattened dataset is easier and more efficient to query, so should be used for most analysis and reporting.

Access

Everyone with a @digital.cabinet-office.gov.uk account (all GDS staff) has access to this data by default.

In addition, everyone who requests and is granted access to the GOV.UK GA4 data will be given access to query this raw dataset. More information can be found in our GA access policy.

Location

There are 3 GA4 datasets. These correspond to the integration, staging, and production or live GOV.UK websites. All of these datasets are made up of sharded tables. This means that a new table is created each day with the suffix YYYYMMDD.

The GA4 data for the live GOV.UK site is located in BigQuery in the ga4-analytics-352613.analytics_330577055 dataset. The GA4 data for the staging site is located in BigQuery in the ga4-analytics-352613.analytics_330580593 dataset. The GA4 data for the integration site is located in BigQuery in the ga4-analytics-352613.analytics_294475112 dataset.

These datasets are all within the GA4 analytics project. For more information on the Google Cloud Platform projects, see our GCP Project Documentation.

Schema

This table uses the default GA4 BigQuery Export schema:

field name type mode
event_date STRING NULLABLE
event_timestamp INTEGER NULLABLE
event_name STRING NULLABLE
event_params RECORD REPEATED
event_previous_timestamp INTEGER NULLABLE
event_value_in_usd FLOAT NULLABLE
event_bundle_sequence_id INTEGER NULLABLE
event_server_timestamp_offset INTEGER NULLABLE
user_id STRING NULLABLE
user_pseudo_id STRING NULLABLE
privacy_info RECORD NULLABLE
user_properties RECORD REPEATED
user_first_touch_timestamp INTEGER NULLABLE
user_ltv RECORD NULLABLE
device RECORD NULLABLE
geo RECORD NULLABLE
app_info RECORD NULLABLE
traffic_source RECORD NULLABLE
stream_id STRING NULLABLE
platform STRING NULLABLE
event_dimensions RECORD NULLABLE
ecommerce RECORD NULLABLE
items RECORD REPEATED
collected_traffic_source RECORD NULLABLE
is_active_user BOOLEAN NULLABLE

Retention

The integration and staging GA4 datasets have a default table expiry in BigQuery of 30 days.

This page was last reviewed on 23 April 2024. It needs to be reviewed again on 23 October 2024 .
This page was set to be reviewed before 23 October 2024. This might mean the content is out of date.