La pagina richiesta al momento non è disponibile nella tua lingua. Puoi selezionare una lingua diversa in fondo alla pagina oppure tradurre istantaneamente qualsiasi pagina web nella lingua che preferisci tramite La funzione di traduzione integrata di Google Chrome.

[UA→GA4] Send events to both your UA and GA4 properties

By dual tagging you can keep your Universal Analytics implementation in place while you build out your Google Analytics 4 implementation.

This dual-tagging approach lets you build a historical record (and your skill base) in Google Analytics 4 while continuing to depend on Universal Analytics until you're ready to switch over.

In this article:

gtag.js dual tagging

If your Universal Analytics property is implemented with gtag.js, you can dual tag for your Google Analytics 4 property in one of the following ways:

When you have event measurement implemented in your UA property and you dual tag through gtag.js, if your UA property has not specified a 'send_to' command, your site will send events to both your UA and GA4 properties. The category/action/label values from your UA events automatically get translated to Google Analytics 4 events and parameters as follows.

  • Event action becomes an event name in the Google Analytics 4 property.
  • Event category, label, and value become event parameters in the Google Analytics 4 property (see below for limits on parameters)
The following is an event in a Universal Analytics property implemented via gtag.js:

1: gtag('event', <action>, {

2: 'event_category': <category>,

3: 'event_label': <label>,

4: 'value': <value>

5: });

The event gets translated to a Google Analytics 4 property using the generalized event signature:

1: gtag('event', <event_name>, {

2: <parameter_1>: <parameter_1_value>,

3: <parameter_2>: <parameter_2_value>,

4: <parameter_3>: <parameter_3_value>,

5: ...

6: });

<action> in the Universal Analytics property maps to <event_name> in the Google Analytics 4 property and 'event_category', 'event_label', and 'value' — along with their respective values— map to parameters with values.

The enhanced measurement feature that is enabled by default in a Google Analytics 4 web data stream captures several types of core user interactions such as file downloads, outbound linking, and video tracking. If you are already tracking these interactions in Universal Analytics, you may want to avoid double counting the same user interactions by disabling them in the enhanced measurement settings.

The automatic event translation described above is a good option if you can't make code-level changes to your website. The downside of this automation is the additional configuration required to make all event dimensions meaningful and usable in Google Analytics 4.

Manually implement events after dual tagging

If you're able to make code-level changes to your site, we recommend that you approach event measurement in Google Analytics 4 with advance planning. Making code-level changes lets you control event parameter names at collection time.

In this case, you can take advantage of enhanced measurement in your Google Analytics 4 web data stream by leaving the tracking options enabled and by avoiding the manually-coded equivalents in the Google Analytics 4 implementation.

Continue to the article Map Universal Analytics events and custom dimensions to Google Analytics 4 for detailed guidance.

Google Tag Manager dual tagging

Google Tag Manager’s modularity and flexibility facilitate the process of building up your Google Analytics 4 implementation while maintaining your Universal Analytics implementation. In most cases, you can use many of the variables and triggers that you defined to populate Universal Analytics to also generate your Google Analytics 4 events and custom definitions.


With Google Tag Manager, you can use many of the same triggers and variables for Universal Analytics and Google Analytics 4 event tracking

analytics.js dual tagging

If your current implementation of Universal Analytics uses on-page calls to analytics.js, you will also need to add gtag.js or Google Tag Manager (or another tag management system) to your pages so you can begin sending data to Google Analytics 4 as well (via connected site tags or via Google Analytics 4 tagging). You can't use the analytics.js library to send data to a Google Analytics 4 property.

Ecommerce migration

The relative complexity of Google Analytics ecommerce tracking warrants special consideration in the context of Google Analytics 4 migration and dual tagging. For more details, see GA4 ecommerce migration in the Google help docs.

Modifying and creating events from the Analytics interface

Google Analytics 4 lets you modify events as they’re processed and also create new events based on other events and parameters. Learn how.

Modifying events

Event modification is comparable to aspects of view settings and view filters in Universal Analytics, but can also be used for more specialized purposes. Let’s consider the three use cases below.

Modifying events for consolidation

Let’s say that the thank-you-page URL for your contact-us submission contains an artifact that is not meaningful for your analysis and therefore unnecessarily fragments the page_location parameter value, e.g.:

You could consolidate page_location and streamline your analysis by configuring an event modification as follows:


Modify event

Modification name

Thank-You-Page Consolidation

Matching conditions
Parameter Operator Value
event_name equals page_view
page_location contains thank-you

Modify parameters
Parameter New value

Modify events to create multiple custom dimensions from the same event parameters

Let’s say that you’re capturing the selections in multiple drop-down fields of a single form as follows:

event: form_selection

parameters: form_name, field_name, field_selection

To capture industry and job title as separate custom dimensions, you could configure event modifications as follows in Google Analytics 4:

  1. On the left, click Configure > Events > Modify event > Create.
  2. Configure and save the event modification as follows:

    Modify event

    Modification name

    Map form_selection to Industry CD

    Matching conditions
    Parameter Operator Value
    event_name equals form_selection
    form_name equals lead-form
    field_name equals industry

    Modify parameters
    Parameter New value


  3. On the left, click Configure > Custom definitions > Custom dimension > Create custom dimensions.
  4. Configure and save the custom dimension as follows:

    New custom dimension

    Dimension Name Scope Event parameters
    Industry User industry_selection


  5. Repeat the steps above for the job title drop-down.

Modifying events to create more meaningful Google Analytics 4 event parameters with connected site tags

As outlined above, you can use connected site tags to collect data in a Google Analytics 4 property based on an existing gtag.js implementation of Universal Analytics. The challenge with this approach is to generate meaningful event parameters from the generic event_category, event_label, and custom dimension names that the connected site tag would push into Google Analytics 4 by default.

The event modifications in this case would be very similar to the previously outlined case and look something like:

Modify event

Modification name

Map event_label to social_network

Matching conditions
Parameter Operator Value
event_name equals connect
event_category equals social
field_name equals industry

Modify parameters
Parameter New value


Creating events

Creating events is especially useful for creating new events that you can designate as conversions in response to other events you collect. For more details, see Create a new conversion event via the user interface.

See [GA4] Modify and create events in the Analytics help center for more details on both of these processes.

È stato utile?
Come possiamo migliorare l'articolo?
Cancella ricerca
Chiudi ricerca
App Google
Menu principale
Cerca nel Centro assistenza