Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What's the advantage of client-side analytics over server-side?

I've always used client-side web analytics that uses JavaScript to track visitor hits to the site, and all the useful information that gives. But some people have recently told me they prefer server side analytics because it's faster.

So what I wondered is what are the main advantages of doing it client-side with JavaScript? Which has more features and why?

like image 670
David Ball Avatar asked Nov 21 '11 11:11

David Ball


People also ask

Is client-side better than server-side?

Between the two options, server-side rendering is better for SEO than client-side rendering. This is because server-side rendering can speed up page load times, which not only improves the user experience, but can help your site rank better in Google search results.

What is the difference between server-side and client-side tracking?

A client-side event usually comes in the form of a tag and is sent directly from the client to Indicative or a tag manager (like Google Tag Manager). These tags are sent when an event like page view or button click is fired. A server-side event is an event that goes from a web server to Indicative.

Is Google Analytics client-side or server-side?

When you use Google Analytics, the data is tracked and stored on Google's servers, not your own. Because of this, there are many different analytics programs and integrations available that offer client-side tracking.


1 Answers

Server or Client side for Analytics?

Server-side Advantages:

  • Servers can be set up with infinitely more power than desktop machines and so can crunch "the big numbers".

  • Performance can be more predictable as the same machines are used for everyone's analysis and generation of results.

  • Output will not have dependencies on browser / browser version as they just have to display an image.

  • Output can also be multi-device without any dependencies.

  • Output can be the same everywhere both reducing client issues and also making the image generation be about supporting 1 output format over many.

Client-side Advantages:

  • If the number of clients is large, say thousands per minute, it can be good to unload the processing to client machines to avoid having them slow down a central server.

  • Solutions tend to provide more interactivity and faster results as all the data and the logic is on the client.

  • Once downloaded initially, views can be changed without being online.

  • If the traffic varies a lot, say sometimes a few queries per hour, other times, hundreds per minute client-side makes sure that a central server is not over-loaded by this effort

  • Server-side infrastructure will not be needed and so will not cost (the provider) money.

like image 183
Michael Durrant Avatar answered Nov 05 '22 05:11

Michael Durrant