Skip to content

Google Universal Analytics will be EOL July 2023 #35204

Closed
@rhoerr

Description

@rhoerr

Summary (*)

Per https://support.google.com/analytics/answer/11583528 (at time of writing):

Universal Analytics will be going away

Google Analytics 4 is our next-generation measurement solution, and it's replacing Universal Analytics. On July 1, 2023, standard Universal Analytics properties will stop processing new hits. If you still rely on Universal Analytics, we recommend that you prepare to use Google Analytics 4 going forward.

Understand what's going to happen

Until July 1, 2023, you can continue to use and collect new data in your Universal Analytics properties.
After July 1, 2023, you'll be able to access your previously processed data in your Universal Analytics property for at least six months. We know your data is important to you, and we strongly encourage you to export your historical reports during this time.

Magento_GoogleAnalytics currently implements analytics.js and its associated ga(...) function calls. Based on the info above, starting 2023-07-01, that will become completely nonfunctional (no longer collecting data). Continuing to use Google Analytics services will require implementing Google Analytics 4, which uses gtag.js and gtag(...) calls with event-based tracking.

This affects all Magento and Adobe Commerce installations 2.0 to 2.4.

Examples (*)

Magento_GoogleAnalytics currently uses analytics.js for Universal Analytics:

            (function (i, s, o, g, r, a, m) {
                i.GoogleAnalyticsObject = r;
                i[r] = i[r] || function () {
                        (i[r].q = i[r].q || []).push(arguments)
                    }, i[r].l = 1 * new Date();
                a = s.createElement(o),
                    m = s.getElementsByTagName(o)[0];
                a.async = 1;
                a.src = g;
                m.parentNode.insertBefore(a, m)
            })(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');

            // Process page info
            ga('create', config.pageTrackingData.accountId, 'auto');

Per above, in July 2023, this will stop collecting data and no longer function as intended.

Proposed solution

Implement Google Analytics 4 far in advance of 2023-07-01 to allow merchants to transition to the new data collection platform.

Implementing GA4 will require total overhaul of the current implementation: https://support.google.com/analytics/answer/10119380?hl=en&ref_topic=11192706

See also

Deprecation/EOL notice: https://support.google.com/analytics/answer/11583528
Migration guide: https://support.google.com/analytics/answer/10759417?hl=en&ref_topic=10737980
Previously reported in #12941


  • Severity: S2 - Affects non-critical data or functionality and forces users to employ a workaround.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Area: Analytics / ReportingArea: FrameworkIssue: ConfirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedPriority: P1Once P0 defects have been fixed, a defect having this priority is the next candidate for fixing.Progress: doneReproduced on 2.4.xThe issue has been reproduced on latest 2.4-develop branchTriage: Dev.ExperienceIssue related to Developer Experience and needs help with Triage to Confirm or Reject it

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions