Google Analytics and cookies

A few days after the launch of Google Analytics, the web is already buzzing about Google’s shiny new toy. So many people rushed through the door that the service promptly buckled under the weight. Nothing says successful launch quite like making the product temporarily unusable.

Things seem to have settled down now, though, and Google Analytics is up and running. There is, however, an interesting little detail hiding in the machinery. Google Analytics uses cookies, but those cookies appear to originate from the site running Analytics rather than from Google itself. Google explains that its JavaScript was designed to coexist peacefully with existing cookies, with Analytics cookie names beginning with _utm to avoid collisions.

Technically neat. Legally, perhaps a little more interesting. Visitors to a site using Google Analytics can therefore receive cookies apparently issued by that site, even though Google’s code is responsible for putting them there. And here in the European Union, we’ve had legislation for a couple of years requiring websites using cookies to inform visitors about it.

So a perfectly innocent site owner who has never knowingly baked a cookie in his life may suddenly find himself serving them because Google showed up with the flour.

The cookies are also remarkably optimistic creatures, with expiry dates stretching all the way to 2038. Apparently Google is planning ahead for a glorious future in which we’re all still using browsers, clicking banner ads and wondering why the flying cars never arrived.

There are other compromises. Analytics data takes several hours to appear, so forget about casually checking who wandered through your site during lunch. For many people this probably doesn’t matter. I find it mildly disappointing. If I’m going to indulge in the grubby little pleasure of watching strangers visit my website, I’d at least like the gratification to be immediate.

And naturally the whole thing depends on JavaScript. Disable it, block it or use something that doesn’t support it, and you quietly disappear from Google’s version of reality.

Still, Google Analytics looks destined to wipe out a considerable population of those little visitor counters that have been blinking away at the bottom of websites for years. Few will mourn them. And if Google Analytics isn’t your thing, there are still alternatives such as server-side AWStats or Statcounter.

The web survived before Google knew exactly how many people visited your site. Presumably it will survive a little longer.

1 comment

  • avatar
    Jake
    05 Dec, 2005
    It's possible to delete the cookies: http://www.customizegoogle.com/block-google-analytics-cookies.html

Leave a reply