<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Azaan Ali Raza</title>
    <description>The latest articles on DEV Community by Azaan Ali Raza (@azaanaliraza).</description>
    <link>https://dev.to/azaanaliraza</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3998575%2F1b80bb02-5f5f-4199-bfd5-11dd99afc7c0.jpg</url>
      <title>DEV Community: Azaan Ali Raza</title>
      <link>https://dev.to/azaanaliraza</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/azaanaliraza"/>
    <language>en</language>
    <item>
      <title>I Built a 2.8KB Cookieless Analytics Tool After Google Analytics Hid 35% of My Traffic</title>
      <dc:creator>Azaan Ali Raza</dc:creator>
      <pubDate>Tue, 23 Jun 2026 19:57:49 +0000</pubDate>
      <link>https://dev.to/azaanaliraza/i-built-a-28kb-cookieless-analytics-tool-after-google-analytics-hid-35-of-my-traffic-36o1</link>
      <guid>https://dev.to/azaanaliraza/i-built-a-28kb-cookieless-analytics-tool-after-google-analytics-hid-35-of-my-traffic-36o1</guid>
      <description>&lt;p&gt;Last month my Next.js SaaS showed 1,200 visitors in Google Analytics.&lt;/p&gt;

&lt;p&gt;&lt;a href="//amazematrix.com"&gt;AmazeMatrix&lt;/a&gt; showed 1,847.&lt;/p&gt;

&lt;p&gt;That's 35% of my traffic GA simply missed because of ad blockers and cookie consent rejections. I am 20, building from Meerut, and I was making product decisions on broken data.&lt;/p&gt;

&lt;p&gt;So I deleted GA and built my own.&lt;/p&gt;

&lt;p&gt;The problem&lt;br&gt;
I launched &lt;a href="//amazematrix.com"&gt;AmazeMatrix&lt;/a&gt; in early 2026 with GA4 installed. Three things broke immediately:&lt;/p&gt;

&lt;p&gt;The cookie banner killed UX. 60% of Indian users clicked "Reject". My bounce rate jumped.&lt;br&gt;
Ad blockers ate my data. Over 40% of internet users run blockers that kill analytics cookies by default.&lt;br&gt;
Speed. GA's script was 45KB. My LCP went from 1.9s to 3.1s on mobile.&lt;br&gt;
I tried the privacy tools everyone recommends:&lt;/p&gt;

&lt;p&gt;Plausible — $9/mo, super clean, but no heatmaps, no Core Web Vitals&lt;br&gt;
Fathom — $15/mo, managed, but no AI insights, no India pricing&lt;br&gt;
OpenPanel — $2.50/mo, great product analytics, but I still needed timeline annotations for deploys&lt;br&gt;
I didn't want 4 tools. I wanted one lightweight snippet that gave me traffic, speed, and why things changed.&lt;/p&gt;

&lt;p&gt;Investigation: how cookieless actually works&lt;br&gt;
I spent a week reading how the good ones do it. Three patterns:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;No persistent cookies. Instead of storing an ID for months, you generate a daily rotating hash from IP + user agent + salt that changes every 24h. You can count uniques today, but you can't track someone forever.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Server-side or edge capture. If the browser never sets a cookie, ad blockers have nothing to block.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Relative coordinates for heatmaps. Instead of sending screenshots (heavy), you send x/y as percentages of the element. That's under 0.2KB per click.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;That was the blueprint.&lt;/p&gt;

&lt;p&gt;Solution: I built AmazeMatrix&lt;br&gt;
Tech stack I chose because I live in Next.js 16:&lt;/p&gt;

&lt;p&gt;Frontend: Next.js App Router, Tailwind, Framer Motion&lt;br&gt;
Edge: Cloudflare Workers / Vercel Edge&lt;br&gt;
DB: Neon Postgres + Drizzle ORM&lt;br&gt;
Auth: Better Auth&lt;br&gt;
AI: Gemini SDK&lt;br&gt;
Billing: Razorpay (because Stripe doesn't work for most Indian founders)&lt;br&gt;
The entire snippet is 2.8KB gzipped:&lt;/p&gt;

&lt;p&gt;3 lessons I learned building privacy analytics&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;Don't fingerprint, rotate.&lt;br&gt;
I first tried a persistent hash. It felt creepy and broke privacy laws. Daily rotating hash gives me accurate daily uniques without storing PII. Privacy-first is not a marketing line, it's an architecture choice.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Heatmaps don't need images.&lt;br&gt;
Everyone sends full-page screenshots. I send {x: 0.42, y: 0.18, el: '#pricing'}. That's 18 bytes. Multiply by 10k clicks and you save megabytes.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Founders don't want another dashboard, they want answers.&lt;br&gt;
The most used feature is not the graph. It's the AI chat. "How is page speed affecting sales?" gets more clicks than any chart.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;How you can try it&lt;br&gt;
I kept it stupid simple:&lt;/p&gt;

&lt;p&gt;Sign up, get siteId&lt;br&gt;
Paste 2 lines&lt;br&gt;
See data in 10 seconds&lt;br&gt;
Free for first 7 days&lt;/p&gt;

&lt;p&gt;I'm building in public on X and Threads as [@razavi_azaan]. If you want the self-host Docker compose, comment "self-host" and I'll DM it.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>webdev</category>
      <category>startup</category>
      <category>saas</category>
    </item>
    <item>
      <title>I thought 200 people visited my site. It was 11.</title>
      <dc:creator>Azaan Ali Raza</dc:creator>
      <pubDate>Tue, 23 Jun 2026 11:00:59 +0000</pubDate>
      <link>https://dev.to/azaanaliraza/i-thought-200-people-visited-my-site-it-was-11-50ic</link>
      <guid>https://dev.to/azaanaliraza/i-thought-200-people-visited-my-site-it-was-11-50ic</guid>
      <description>&lt;p&gt;3 AM. Launch night.&lt;/p&gt;

&lt;p&gt;Google Analytics said 200 visitors. 12 signups. I was buzzing.&lt;/p&gt;

&lt;p&gt;Then my co-founder messaged me:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"Bro your site isn't loading any scripts on my work laptop."&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;I checked. uBlock Origin — blocks GA. Privacy Badger — blocks GA. His company firewall — blocks GA.&lt;/p&gt;

&lt;p&gt;I wasn't reading my traffic. I was reading the survivors.&lt;/p&gt;




&lt;p&gt;I pulled the real number the next morning.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;11 people.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Not 200. Eleven.&lt;/p&gt;

&lt;p&gt;I had spent 6 hours that week A/B testing headline copy. Rearranging buttons. Tweaking CTA colors. All of it — based on data that was missing 95% of my actual visitors.&lt;/p&gt;

&lt;p&gt;That's when I stopped using Google Analytics. And started building AmazeMatrix.&lt;/p&gt;




&lt;p&gt;The idea was simple: analytics that can't be blocked.&lt;/p&gt;

&lt;p&gt;No cookies. No third-party domain. Script loads from &lt;em&gt;your&lt;/em&gt; domain as a first-party request. Blockers don't see it. Firewalls don't flag it. Under 2KB so it doesn't slow anything down.&lt;/p&gt;

&lt;p&gt;First week of running it on a real site?&lt;/p&gt;

&lt;p&gt;Actual traffic was &lt;strong&gt;less than half&lt;/strong&gt; of what GA reported. Gone. Invisible. Making decisions off ghost data.&lt;/p&gt;




&lt;p&gt;Building it wasn't clean either.&lt;/p&gt;

&lt;p&gt;My "active visitors" counter hit 47 on a page with 8 real sessions. Bounce rate was firing before the page finished loading. Three beta testers churned silently — a CSP header was eating my script and nobody told me.&lt;/p&gt;

&lt;p&gt;Every bug made me angrier at GA for normalising bad data.&lt;/p&gt;

&lt;p&gt;I fixed all of it. Session expiry. SPA route tracking. A CSP handshake so you &lt;em&gt;know&lt;/em&gt; the script fired before you trust a single number.&lt;/p&gt;




&lt;p&gt;The tagline wrote itself:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Know more. Track less.&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Frzidpyy5sitwh69k5ivo.png" alt=" " width="799" height="535"&gt;
&lt;/h2&gt;

&lt;p&gt;If you're building something and quietly suspect your analytics are lying to you — they probably are.&lt;/p&gt;

&lt;p&gt;Early access is open → &lt;strong&gt;&lt;a href="https://amazematrix.com" rel="noopener noreferrer"&gt;amazematrix.com&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Drop your current analytics stack in the comments. Genuinely curious how many people have caught GA lying.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>webdev</category>
      <category>saas</category>
      <category>showdev</category>
    </item>
  </channel>
</rss>
