title: Why does Google Analytics cross-domain tracking across an iframe require tracking snippets in both domains?
body: <p>I'm creating a shareable widget, for anyone to copy onto their website. The shareable piece of code is an frame that points to the actual widget that lives on our hosted site (i.e. ourdomain.com). If we ever want to tweak the actual widget, we can do so in one place, with no effect on the iframes pointing to it from other sites we have no control over.</p>
  
  <p>I tried the approach of cross domain tracking. While I was analyzing the results, I observed that the path of the shared widget code (not on our domain) appears within the content view in GA. This runs counter to a response from my <a href="https://stackoverflow.com/questions/3983110/google-analytics-multiple-trackers-on-one-page-traditional-and-asynchronous">previous post</a> "if it is being inserted into many domains you are going to need to set up multiple GA accounts and use different account numbers per user."</p>
  
  <p>Correct me if I am wrong: Any tracking code using our unique account id will appear in our GA by default, no matter where it's hosted, whether the code is implementing cross domain tracking or not.
  <a href="http://www.google.com/support/forum/p/Google+Analytics/thread?tid=6af5b4c3e30c71be&amp;hl=en" rel="nofollow noreferrer">http://www.google.com/support/forum/p/Google+Analytics/thread?tid=6af5b4c3e30c71be&amp;hl=en</a></p>
  
  <p>Since any page that hosts GA tracking code shows up in our content view, I could locate where the widget is being viewed by simply looking for all pages whose name did not include ourdomain.com. Of course this includes proxy servers as well, but I was going to also include a custom variable so I could implement a filter based on the custom variable.</p>
  
  <p>So explain to me where this breaks down or what I'm missing here. Is there some amount of data I am losing here because the GA cookie is not in fact being utilized? Give me a good reason why I should put in the effort to fully implement cross domain tracking, including the necessary P3P implementation on our server for IE visitors.</p>
  
  <p>As a sidenote, I am considering adding GA tracking code with an event tracker within the widget itself to track when people actually USE the widget (as distinct from the when the widget is loaded). I understand that by not implementing cross domain tracking I would not be able to obtain any data about the visitor, only whether the widget was acted upon or not. </p>