Take the 2-minute tour ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

Traffic coming form shortened URLs like bit.ly, do they show up in Google Analytics as direct or do they keep their real referrer?

Ex.: if someone types in a bit.ly link it counts as direct, but if someone clicks a bit.ly link from Twitter, it counts as referral traffic from Twitter?

share|improve this question
add comment

3 Answers

I did some research and found that; the traffic categorized by Google Analytics will be vary by URL shortener website.

Refer to this link for more information:

share|improve this answer
add comment

The URL shortening services bit.ly and tinyurl.com return a 301 Moved Permanently HTTP status - ie. a URL redirect. The browser then sends a new request to the new (ie. long) URL, passing the referer again. AFAIK this is the same for most mainstream URL shortening services.

If the service performs a 301 redirect (as it should) then the browser repasses the referer. In this case I can see no reason for Google Analytics to not show this referer in its reports.

Note, however, that the browser itself can be configured to suppress the HTTP referer, or even send something completely erroneous.

Traffic coming form shortened urls like bit.ly, do they show up in Google Analytics as direct or do they keep their real referrer?

They keep the real referer. This might also be "direct", if indeed it was a direct request.

Ex. If someone types in a bit.ly link it counts as direct, but if someone clicks a bit.ly link from Twitter, it counts as referral traffic from Twitter?

Yes. Note that twitter now wraps all its URLs in its own URL shortening service, so the referring URL is of the form http://t.co/xyzxyz.

An Example

The following shortened URLs all redirect to a page that shows the HTTP referer.

You can see that by following any of the above links, the HTTP referer is passed (providing your browser is set to do so). If you copy and paste the URL in a new browser window then no referer is passed - it is a direct link.

HTTPS - Secure connections

Just an additonal note about links from secure content (HTTPS) to non-secure content (HTTP) - this affects any kind of link, not just URL shorteners. In this case the HTTP referer header is not set by the browser.

Clients SHOULD NOT include a Referer header field in a (non-secure) HTTP request if the referring page was transferred with a secure protocol.

Source: RFC 2616 Section 15.1.3

JavaScript Redirect

However, a JavaScript redirect will destroy the original referer.

  • This page does a JavaScript Redirect to the same page as above (which shows the HTTP Referer). But instead of passing the original Referer (ie. this page), the HTTP Referer is the intermediary page that contains the JavaScript redirect.
share|improve this answer
add comment

As a reference, this article lists many of the most popular URL shorteners and indicates what type of redirect they use.

http://searchengineland.com/analysis-which-url-shortening-service-should-you-use-17204

share|improve this answer
    
Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference. –  John Conde Jan 27 at 15:28
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.