ampproject / ampproject/amphtml

🐛 Google Analytics 4 Related Bug: Session Attributed as Unassigned for GA4

Open
#39,730 1 comment 2 reactions 1 assignee Claimed by @erwinmombay View on GitHub
Component: amp-analytics Component: GA4 Stale Type: Bug
Dominant language
JavaScript
Stars
14.9k
Forks
4.1k
PR merge metrics
No merged PRs in 30d

Description

### Description

After installing the GA4 since last month, we figured out that most of our traffic channel group fell under the "Unassigned" attribute. Compare to previously in the GA3, the user was attributed properly as "google" traffic.

When we tried to access the page for the first time, the channel group is attributed as "google". Our hypothesis for now is if the session is timeout, amp-analytics for GA4 cannot attribute back to the first channel group when user visit the website.

### URL where we can debug and reproduce the problem

https://www.google.com/amp/s/iprice.my/computing/

### Reproduction Steps

- Visit the iprice website from the google
- click on any link from iPrice
- Observe the GA dashboard, user attributed correctly from "google"
- when the session timeout, seems new session attributed as "Unassigned"

### Relevant Logs

_No response_

### Browser(s) Affected

Chrome, Firefox, Safari

### OS(s) Affected

_No response_

### Device(s) Affected

_No response_

### AMP Version Affected

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.