Stuifbergen.com

Analytics & Growth Hacking

  • About
  • Contact
  • Professional Services

Find me here

  • Mastodon (social)
  • Mastodon (measure)
  • No more Twitter
You are here: Home / Blog / Making sense of Page Views in GA4

Making sense of Page Views in GA4

17 February 2021 by jules 11 Comments

Since everyone and their uncle is now jumping on the Google Analytics 4 bandwagon, what you’ll see is a lot of basic implementations of GA4.

And that is not at all bad. With a simple base tag and automatic measurements in place, you’ll get a lot. Engagement, scroll events, file downloads.

And of course, the good old page_view. I want to feature this core event in this post, to make your life a bit easier.

What is collected in a default page_view?

Well.. not a lot, really.

The “page_location” is sent – which is the URL, including the https bit, and all url parameters, and a “page_referrer” – which is also in URL form.

What is not mentioned in the documentation above is that there is also a “page_title” that gets sent.

And that Page Title is very prominent in the reports. It’s the default.

And.. not without a reason, because the only other thing is the page_location, which is.. very unreadable.

A bit more readable is the “Page path” dimension in the GA4 interface. This is basically the page_location with the protocol and hostname stripped, but not the query parameters – those are still there.

Exclude Query Parameters: nope

GA4 currently has no option to exclude query parameters in the configuration section, like Universal Analytics had, in the view level.

This means that all pages with fbclid , msclkid and even gclid will be there in your reports, making your precious page paths unique.

Not nice.

This means you will have to work around it during collection time.

Workaround

In the base tag of GA4, you can send a field that I like to call “clean_path“, and fill that with the GTM built-in variable {{Page Path}}.

In that way, you have your lovely clean Page Paths available in GA4.

Make sure to add this parameter to your GA4 custom dimensions, too, so it will be available in the reports and in Data Studio.

Content Grouping

Pretty recently (as everything in GA4) this little drop-down item popped up:

With no indication of Content Grouping in the documentation, I was left wondering..

Can this field be populated? Will there be 5 groupings? Or just one?

After some experimenting, you can indeed use it via the content_group parameter.

Unfortunately, the content_group2 parameter does not work for now.

And as always with GA4:

To be continued..

I will keep updating this post if there’s changes to this event. Thanks for reading!

If you liked this article, why not tweet a little link:

Making sense of Page View events in GA4 (and how to handle pesky url parameters) Click To Tweet

Thanks!

Related posts:

ParisSession modeling in BigQuery SQL (using GA4 data and a trip to Paris) Conversion Attribution: a Markov model (using Google Analytics and the R ChannelAttribution package) Default ThumbnailGTM For WordPress (gtm4wp) Container with Google Analytics Tags GTM Monitoring in Google Analytics

Filed Under: Blog Tagged With: ga4, Google Analytics

Liked this post?

Buy Me a Coffee

Comments

  1. Luis Madrid says

    23 February 2021 at 12:04

    Thank you por the post Jules. I was considering on set the {{Page Path}} variable as a default value for the page_location parameter but I was afraid this method was going to affect other traffic attribution parameters like utms reading, etc…
    ¿Have you tried it?

    Reply
    • jules says

      23 February 2021 at 13:22

      page_location is built-in, I wouldn’t change it, it might break something.

      Reply
      • Andrew says

        6 March 2023 at 17:00

        Thaks for the tips.

        One more disapointing from new update.

        Anyway, maybe using a dataLayer to separate content will be more usefull.

        Like

        window.dataLayer = window.dataLayer || [];
        window.dataLayer.push({
        “event”: “pageview”,
        “pageType”: “Blog”,
        “pageLanguage”: “EN”,
        “pageRubric”: “Analytics”,
        “pageTag”: “aaa, bbb, ccc”
        });

        So, you going to be able to use more useful Content Grouping and add additional information for the next steps.

        Reply
        • Andrew says

          6 March 2023 at 17:06

          and one more thing, the Conten group is working only with page_view event.

          Reply
  2. Peter O'Neill says

    14 April 2021 at 10:43

    Hi Jules – I was doing the same experiment yesterday on content grouping, good to get verification before I saw the data through. Given Page Title and Page Path (with query parameters) are fairly useless to us, would you agree that using Content Grouping for a user friendly page name and a custom parameter for Page Type is a decent approach initially? Hopefully with more GA4 features to follow to make this easier.

    Reply
    • jules says

      14 April 2021 at 12:48

      Hey Peter,
      My approach would be to just fill pre-configured dimensions with what they’re meant for (or what they describe), unless your reporting doesn not give what you want.

      In UA I always “Abuse” content groupings and throw in product names for example (so you have “landing page product”, w00t!).

      In GA4 it’s still unclear what the limitions of the reporting interface will become, so any aproach that gives you what you want _now_ is a decent approach.
      But.. if Google is going to release reports, or some AI based on content_groups (“this content group is driving revenue”) it’s good to have a nice amount of backfill.

      (so.. a long answer that can be summarized as “it depends”)

      Reply
      • Peter O'Neill says

        14 April 2021 at 17:26

        I would say that right now the reporting interface for GA4 is frustratingly unusable so difficult to predict what will be available. Good to see we will have content groupings and channel groupings – I think more need to be added to classify & group dimensions (also to hide irrelevant dimensions from view).

        It seems like a waiting game until more features are released so we then know how to design our solutions.

        Reply
  3. Fernando says

    6 April 2022 at 02:02

    Hi Jules,

    do you know any way to strip the query parameters from GA4 without using GTM? There is a website that I cant use GTM and it these parameters are driving me nuts… Can’t figure why google team decide on removing some key tools from GA4…

    Reply
    • jules says

      21 April 2022 at 20:36

      There is currently no way of doing it without GTM.
      In Data Studio, the page path dimension is clean, so you at least have a version with ALL parameters stripped.

      Reply
  4. roel says

    20 April 2022 at 17:16

    thanks! useful

    Reply
  5. Matheus says

    29 April 2022 at 15:38

    I was going through some documentation and you’re also able to replace the page_title by sending it as a parameter in the pageview. Unless I’m doing something wrong and didn’t notice this seem to be a good way of “fixing” this

    Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Recent Posts

  • Analyze AB tests in GA4 via Big Query
  • How to make sure your GA4 events tables do not expire
  • Prepare your cloud project for “Bulk data export” Google Search Console
  • Making Sense of the GA4 Configuration Tag
  • Using Big Query to calculate DAU / MAU

Need help?

  • Contact me

Search

© Copyright Jules Stuifbergen · Powered by Genesis ·