Analytics for single-page applications

I’d like to better understand how the Netlify Analytics works with single-page applications. Given it’s sever-side, I can’t imagine that it would correctly capture page navigation as users move through the site.

In my specific case I’m using Gridsome (Vue version of Gatsby).

Can anyone provide further insight into this?

Thanks in advance.

Hi! Welcome to the forum!

At the moment, Netlify Analytics isn’t really set up for SPAs. As you say, we aren’t capturing navigation events that happen purely on the client-side - we’re strictly collecting server requests only.

But! I have some good news. We are working on a mechanism that’ll allow folks building SPAs to send events to us, so that you can start to track those client-side events for yourself and get a better idea of your activity. So, just keep your eyes peeled for that update. :slight_smile:

3 Likes

Awesome - I look forward to that update.

1 Like

Any update to this? Can we subscribe somewhere to know when this feature becomes available?

hi there,

the best place to watch is literally this thread! I am checking in on this with the responsible team, and we will post an update as soon as we have one available.

1 Like

Very interested in where this is, need a solution like it soon or I’ll have to turn to some other 3rd party provider.

I noticed that Netlify analytics offers analytics insights into “Top sources & pages” (reference here). How does this work with SPAs like ones made with React or Vue. The way I understand it is that apps made with these frameworks simply serve the associated app.js bundle with some basic html and load the routes all entirely on the client side via js.

If routes are all loaded on the client side, how does Netlify’s server side analytics know which pages were hit?

hi @RohanKapurDEV - i moved your thread here as it is the same topic. I’m checking in with the team responsible for this work to see if we have any updates.

1 Like

Hey @perry! Any update from the team on this one? :slight_smile:

i wish I had an update! at the moment, nothing yet. It’s not off the table, but, I don’t have anything specific or an ETA on this yet. Sorry, I wish i had better news :expressionless:

@perry :wave:, still nothing ?

Hi there, @sidati :wave:

Like Perry said in January, I wish I had an update! As of right now there is no ETA on this changing. Should there be a change in the future, we will follow up on this thread.

Thank you!

1 Like