
Hi, I'm Richard. On this blog, I share thoughts, personal stories — and what I'm working on. I hope this article brings you some value.
I built my own analytics with the help of AI – cookie-free and GDPR-compliant
By Richard Golian13 April 2025 Castellano Français Slovenčina
Not long ago, I realized I wanted a better understanding of my blog’s traffic.
I like clean and accurate data. But traditional analytics tools like Google Analytics come with serious downsides: inaccurate numbers (due to blocked consent requests and various tracking blockers), the need for a cookie banner, and questionable transparency around privacy.
That’s why I decided to build my own analytics – with pure, unfiltered data and full respect for the privacy of my visitors. And since we’re living in 2025, I built it with the help of generative AI.
When it comes to programming, I’ve always considered myself an eternal beginner, ever since I started with web development at the age of 13. But AI has opened up skills and opportunities for me that I never imagined I would have. I’ve already written here on my blog about how AI helps me improve my coding skills, explaining its steps and decisions along the way. Thanks to that, my horizons have expanded far beyond what I thought possible. One of the results is my own custom-built analytics tool.
Defining the Goals and First Prompts
When building a project like this today, you really need to have a clear idea of what you want it to do and why. Just saying "I want my own analytics" isn’t enough.
So we started by defining exactly what I wanted to measure: daily traffic, traffic sources, purchases of my premium articles, and a deeper analysis of visitor types (humans vs. suspicious activity vs. bots).

At first, creating the initial tables and charts seemed easy. But it didn’t take long before the first real challenges emerged.
The issues I had to solve
The first SQL queries we used were slow and inefficient. They dragged the whole website down. We gradually tuned them, replaced wasteful LIKE comparisons with exact matches, and optimized the logic to only process the data we really needed – and suddenly, it started to fly.
Continue reading:
Would you like to dive deeper into this topic, see how I think, and have the chance to ask me a follow‑up question? The full version of this post will be sent to your email.

If you have any thoughts, questions, or feedback, feel free to drop me a message at mail@richardgolian.com.