-
How to include website domain in GA4 Google Analytics?
You know, I’ve been using this bit of code to append variables to each page for Google Analytics tracking:
function pageViewGa(pagePath, pageUrl, host) { gtag("event", "page_view", { "page_title": pagePath, "page_location": pageUrl, "page_path": pagePath }); }
It’s been working well for the most part, but there’s something I’d like to add. I can’t seem to figure out how to get the hostname to show up on Google Analytics. You wouldn’t happen to know how I can do that, would you? Here’s a screenshot for reference:
Log in to reply.