Forum Academy Marketplace Showcase Pricing Features

Google Analytics for Single Page Apps

Hey guys!

I have a Bubble website built by the agency as a Single Page application, which is great for loading speed and other stuff so it was pitched to me. Now the problem that I am facing is that Google Analytics does not recognise the dynamic links of my website which is a major issue for me.

To give you a little back ground:

  1. Initially I connected GA via Bubble plug in, enabled standard Bubble site map and submitted it to the Search Console. After some traffic started to float into the website I have notice this →

The domain sits on letzcompare.lu/ and once the website is fully loaded, the home Page URL actually is /?v=main (don’t ask me why as it was in the hands of an agency). So basically what’s happening is that website loads at LetzCompare.lu/ and then immediately redirects to /?v=main which is not indexed or anything at all.

  1. As the next step I figured that perhaps it is my sitemap is not good, cause the default Bubble map only contains letzcompare.lu/ and 404 page. Nothing else. So I created a custom map for all my 56 dynamic URLs and resubmitted to Search Console.

That gave 0 result.

  1. I have switch my GA from plugin to Tag manager. At the same time I found an article on Google about the issue with single page apps and how should I adjust my tracking code. So I did exactly that.

That also give 0 result. Even worth. If with previous set up and updated site map I saw slight improvement in the avg session duration and bounce rate (btw both of them were at 2 sec and 98% :pensive:) so now everything is at 0sec and 100% bounce rate.

Can someone please help me figure out my Google Analytics setup and what can I do to fix it?

Thank you!

1 Like

I’ve not actually done this myself with parameters but have come across reading about the issue with GA & using parameters for page navigation. (vs path vs #hash vs send events) I think its a GA issue where you have to customise GA to understand your page parameters. This article seems good - Setting up Google Analytics site search (with and without parameters) – Loves Data

Personally I would take a different approach. Because (it appears) you have a workflow that is controlling all the navigation in your site, (probably on page load of index) you probably can take a different approach and control it all from that controller/router in your workflows - with sendevents. You could do it with Gtag and javascript or my plugin possibly could sort this out very easily. Google Analytics 4 Single Page Apps Plugin | Bubble

Both approaches would work I expect. If you are more comfortable figuring out GA - then get the parameter approach working. If you are more comfortable with Bubble or give up on the parameter approach - consider using the sendevent approach. (either with a plugin or do the js yourself).

1 Like