How to add ‘Previous Page Path’ from UA into GA4 (and include it in your Looker Studio reports)

Analyst solving their problem in Google Analytics

One of the more irritating changes in GA4 has been the apparent loss of the Previous Page Path dimension from Universal Analytics (UA). But in fact, Previous Page Path isn’t gone. It’s just hiding. Not as many people are familiar with the Page Referrer dimension, but when it comes to internal traffic on your site, it is basically equivalent to Previous Page Path.

Note I said internal traffic—not all traffic. When you add Page Referrer to your custom GA4 reports, you’ll notice that when the referring page is coming from outside your website, it just shows the referring host—not the referring host and the referring path. This is due to the way modern browsers work. Though the referring host is still certainly useful, it’s not quite as useful as the full URL. Nevertheless, you still get that full URL when the referring page is coming from inside your website. So for the folks who were fretting that Previous Page Path was gone in GA4, fear no more!

Adding Page Referrer to Looker Studio

But that’s not where the story ends. Many people are also eager to include Previous Page Path in their Looker Studio (formerly Google Data Studio) reports. As with many dimensions in GA4, not all of them are automatically included in Google’s native GA4-Looker Data Studio integration. The way to get around this is to create a GA4 custom dimension that captures the same information as Page Referrer. In the GA4 interface, navigate to Configure >> Custom Definitions and from there, add a custom dimension as pictured in the screenshot below:

The most important thing to get right in the custom dimension configuration is plugging in page_referrer for the Event parameter. That is how GA4 will know which piece of information it should send to Looker Studio. Once you have that in place, you should be able to see your new page referrer custom dimension propagate through to Looker Studio after about a day.

Hopefully this article helped ease your transition from UA to GA4. If you have any other questions about analytics, feel free to reach out to me via my Services page.

Comments

No comments yet. Why don’t you start the discussion?

Leave a Reply

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