Thursday, March 5, 2009

Link Shortening and Traffic Monitoring

Twittstract: How to use link shortening to track traffic to your site and to track who clicks on all of those links you've been posting to other sites.

Link shortning services are starting to become pretty important to sharing. With the advent of twitter, (perhaps the original) seems to be a waste of characters when services like and save those last few characters so that you can make your witty point or to get your message out to your members/followers.

In normal person terms, a link shortener is just a redirect to your site. Instead of some long, crazy link such as you can present your twitter followers or your email blast recipients with a nice or even a nice which can fit better into your blog post or email blast or twitter update (see my caution about "readable string" below). When someone clicks on your link, they are taken first to the redirecting site and then off to the link you want them to see. If you are fortunate to work for an organization with a short domain name, you can even create your own link shortening service for use by your staff or customers. I mean, which would you rather look at:


Technology wise, a link shortening service is just a webpage, a database and a random character generator.

It used to be that you could embed javascript into a tinyurl which was handy for tracking codes or other intersting tricks. But, over time I guess that "feature" was abused so, now it's url's only. However, there are still ways to use link shorteners to derrive some information about who clicks your links. For shortened links that you want to direct back to your Google Analytics based site, it is pretty easy. Google makes a link building tool, that will embed information that shows up in your analytics reports to help you know where a click-through originated. Using that tool, I made a link that looks like this:

Disecting the link (the interesting stuff is after the ?) I have told Google that I want the link to appear as if it came from twitter, that the campaign name is Test and that the medium is web. After I put this link through the website it becomes and it goes to the homepage of this blog (apologies if you are reading this in a few months and you get redirected to a more current post). However, the underlying tracking data is retained. This becomes really powerful if you want to test different marketing media. For instance, no one will type this long url:

if I have printed it in the March magazine but they might be willing to type (use the "Optional Custom name" feature) which will not only take them to the blog, but will record that they came from the ad in the March magazine. Note well, the link shorteners work on the principle that 6 character long strings of 60 combinations per character is a gigantic number of combinations (I think there's a factorial involved). However, now that I've taken the character string of "MarchMag" over at, you cannot use it. So, pretty soon, this feature may become worthless for this purpose. Go ahead, click on the links, and then I will post what the Campaigns section of the Traffic Sources reports looks like.

The other way to use link shorteners is to find a way to track the traffic that you send to other sites. Remember that each click will first go to the link shortening site and then off to its destination. If you want to measure the effectiveness of various campaigns or word phrases to get people to click a link then measuring traffic at the shortening site can be valuable. However, unlike the previous example, you aren't getting any traffic on a site you own, so you cannot see the traffic. Fortunately, people smarter than I have decided this is important and already offer the ability to track the redirects. The site we've used in the examples, does it. Other sites that offer similar tracking features are,, and (I'm sure there are more, why not leave a comment with your favorites). Notice something about and that they don't end in .com or one of the familiar 3 character endings. Turns out that each country has been granted a 2 character extension for URL's. In America, we have .us but it is overshadowed by .com, .org and .net. The .ly code that uses is the country code for Lybia and the .im code is for the Isle of Man. Using two character country codes to make intersting url's is probably a whole blog post in itself.

Note to early readers of this post: go ahead, click on the links. It will help use create some pretty graphs to insert into the post so that people can see how all of this works.

1 comment:

Walter said...

Look at this article for even more shorteners

Post a Comment