Flurium Hire

Server Side Analytics

All the analytical information you can collect without relying on client-side javascript.

While developing websites and fighting with the Cookies Concent banner for Google Analytics, I thought about whether it’s possible to move capturing analytics to a server instead of client-side javascript.

Benefits

The benefit is that you offload the client from javascript making the website load faster and deliver a better experience. As well, you will be able to gather information even if javascript is not loaded.

What kind of information

So here is a list of information you can capture on the server without relying on client-side javascript:

It’s quite a lot, isn’t it? It’s literally more than half of the things you would like to collect. So why bother the user with javascript if you already have access to this information on the server?

Implementation

I didn’t implement this yet, but here are 2 ideas you can take:

Saving the analytics record shouldn’t be too costly, but you definitely don’t want users to wait. If you have a multithreading support in your language, then you can go with the background queue right inside your app.

But overall, saving analytics records in middleware is quite a simple and usable approach.

Hopefully, in the future, I will implement this and share more details with you.

Limitations

There is certain information that can’t be obtained without client-side javascript. Here are examples:

Conclusion

You can move a significant amount of analytics to the server. This will help to reduce the amount of javascript you are sending to the client. As well as provide analytical data for situations when javascript isn’t available.

Contact

Ready to bring your idea to life? Or just want to ask some question you can't figure out? We are ready to replay as soon as it is possible.

Email roman@flurium.com Open in Gmail