Forum Replies Created

  • Nam

    Member
    6 July 2023 at 11:25 am in reply to: Invalid JSON payload error when using Google Analytics 4

    So the thing is, the analytics reporting API is only going to let you pull out data from Universal Analytics accounts. What you should be doing is using the data API to get info from your GA4 accounts.

  • Nam

    Member
    23 June 2023 at 10:15 am in reply to: Troubleshooting Data Traffic Across Multiple Properties in GA4

    It sounds like you’re experiencing cross-contamination of your GA4 data. This is often a result of mistakenly sending the data from one website to another analytics property. Since you’re using Google Tag Manager, check that each property ID is correctly assigned in each GTM container. This would be the first thing I’d look at given that you’ve mentioned the issue still persists even when creating new properties. You might also want to consider using separate GTM containers for each of your websites to better manage the tags and analytics related to each specific site. This can also make debugging easier if you face any problems in the future.

  • Nam

    Member
    17 June 2023 at 9:16 pm in reply to: Troubleshooting Custom JavaScript Variables in Google Tag Manager

    Sure, let me break it down for you. The function you’ve written is checking if the word ‘stellar’ is in your webpage’s code, right? But here’s the thing: you’re treating ‘document.body’ as a string, and it’s not. It’s actually an HTML object. So, instead of ‘document.body’, you’d want to use ‘document.body.outerHTML’. This gives you the HTML content of the body element as a string, and you can do your search in that.

    But that’s not all. Apparently there’s something called CSP (Content Security Policy) that can block your Google Tag Manager. So you might want to check if that’s happening. Simply look at your console for any error messages, and if you see something related to CSP, there’s your culprit.

    Lastly, the timing when you’re checking this function matters. If the body of your webpage isn’t fully loaded by the time your function is checking for the word ‘stellar’, it might not find it and return ‘false’. So make sure your function runs after the page is completely loaded.

    To summarize: swap ‘document.body’ to ‘document.body.outerHTML’, check for CSP errors, and ensure you’re running the function after the page is fully loaded.

  • Nam

    Member
    14 June 2023 at 4:54 am in reply to: Implementing data retention settings in ga4 using python

    To access data retention settings in Google Analytics 4 (GA4) using Python, the Google Analytics Admin API is needed. It appears, though, that you are presently using the Google Analytics Data API which mainly serves to run reports on the data in GA4 based on specific dimensions and metrics. For the operation you intend to perform – getting data retention settings – you would need to use the Google Analytics Admin API. Unfortunately, as of the time of this response, the Admin API for Python is not available in a stable release yet. Therefore, you might need to directly make HTTP requests as per the method outlined in the link you provided, or wait for the Python version to be released in a stable version.

  • Nam

    Member
    8 June 2023 at 2:24 pm in reply to: Resolving Self-Referral Problems in Google Analytics 4 (GA4)

    Even after adding your website to the ‘unwanted referrals’ list, it might still show up due to a variety of reasons. The most common is caches and cookies not being cleared, meaning the changes haven’t been fully recognized or implemented yet. Also, any current users who already loaded the page before you made changes may still cause your website to appear as a referral. As for the page referrer not being reported, it could be because your website or the referring site is using the ‘noreferrer’ link attribute, which prevents the HTTP referer header from being sent. Additionally, it could be due to certain browser settings; for instance, some browsers do not send the referer information as a privacy measure. If the issue persists, you may want to consider seeking technical help or contact your analytics service for further investigation.

  • Google Analytics 4 (GA4) is a newer version of Google’s web analytics service, which comes with different features compared to Universal Analytics (UA). GA4 emphasizes event-driven data models, addresses changes in privacy requirements, and has improved integration with Google Ads. However, as a result, it may lack certain features that users have come accustomed to with UA. This is primarily because Google’s focus with GA4 has been on developing new capabilities and future-proof solutions, with certain older features sometimes taking a backseat. It does not necessarily reflect that GA4 is a lesser tool, but rather it underscores the shift in analytics methodology and data privacy norms. While some features may seem to be missing, there is the possibility that they may be added in future updates or replaced with new features.