GA snippets for subdomains and best tracking in MOZ
-
Hey there,
I have a blog running at blog.URL.com. I need to add Google Analytics and I want to track the value of this subdomain as separate from the main URL.
Can I do that? If I do a unique snippet in the header of the blog is that the right way to go? The main site is on an antiquated CMS system and will be converted over the next few months to a full on WP site, does that change anything long-term?
Thanks in advance for your help.
Cheers,
Lisa
-
Another option is add a custom variable in Google Analytics and add the snippet to your pages:
ga('send', 'pageview', { 'dimension1': dimension2 });
'dimension1' is the variable which has been setup
dimension2 is the passing variable i.e. 'Blog'
Hope this also helps, the normal GA code will also need to be included, however this will segregate the blog traffic, but include the traffic in your overall view.
It all depends on how you want to view the traffic on the sites.
I also use this method to segregate product groups.
-
Thanks so much Dana, that's exactly what I needed. L--
-
Hi Lisa,
you can add Google Analytics to track the value of the subdomain as seperate from the main. You would need to create a new property in Google Analytics and then place the snippet into each page of your blog site, making sure to not include the one from URL.com.https://developers.google.com/analytics/devguides/collection/gajs/gaTrackingSite?hl=en
Hope that helps!
Good Luck!Dana
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
MOZ Freshweb reported mentions that really does not contain any mention - anyone else experiencing this?
MOZ Freshweb reported links from "traffic.fullcontentrss.com" that doesn't really contain any mention. Is this a MOZ error or is it maybe since fullcontentrss.com has a javascript that pulls data into their own RSS, MOZ ended up crawling partially and as a result not reporting the correct URL? Anyone else experiencing this anomaly?
Moz Bar | | CPR_PTANTONO0 -
Canonical in Moz crawl report
I'm wondering if the moz bot is seeing my rel="canonical" on my pages. There are 2 notices that are bothering me: Overly Dynamic URL Rel Canonical Overly Dynamic URL - This notice is being generated by urls with query strings. On the main page I have the rel="canonical" tag in the header. So every page with the query string has the canonical tag that points to the page that should be indexed. So my question...Why the notice? Isn't this being handled properly with the canonical tag? I know I can use my robots.txt or the tool in Google search console but is it really necessary when I have the canonical on every page? Here is one of the links that has the "Overly Dynamic URL" notice, as you can see the the canonical in the header points to the page without the query string: https://www.vistex.com/services/training/traditional-classroom/registration-form/?values=true&course-title=DMP101 – Data Maintenance Pricing – Business Processes&date=March 14, 2016 Rel Canonical - Every page in my report has this notice "Using rel=canonical suggests to search engines which URL should be seen as canonical". I'm using the rel="canonical" tag on all of my pages by default. Is the report suggesting that I don't do this? Or is it suggesting that I should? Again...why the notice?
Moz Bar | | Brando160 -
Is there anyway to track on-page grader grades for a site?
As opposed to going through the process of inputting the urls and keywords every couple of weeks, is there a way of Moz to send the scores for those keywords and the domain to which the url belongs?
Moz Bar | | DigitalGuru0 -
MOZ Page Grader - Sorry, but that URL is inaccessible?
Hi, I am trying to use the MOZ page grader on this page - https://www.respuestasparaelhombre.com/datos-sobre-disfunción-eréctil-preguntas but it is saying Sorry, but that URL is inaccessible - any ideas? Thanks
Moz Bar | | Jason_Marsh1230 -
Moz and Google Analytics Trouble?
Is anyone else having trouble connecting their MOZ Pro account to Google Analytics?
Moz Bar | | PhiladelphiaWebsiteSolutions0 -
Moz Local Time Frame
I must have missed it. How long does it take Moz Local to do its thing once the service has been paid?
Moz Bar | | RelativeHealing0 -
Are MOZ Analytics dashboards available for other timeframes than the week just gone?
Hi Guys, We're wondering if anyone knows if there is a way to get moz analytics dashboard reports for timeframes other than just the last week? When we view the dashboard report, under the heading there is a 'timeframe' dropdown, however it only ever shows us the previous week as an option. Would be great if anyone knows if this is available now / soon? Cheers, Camille@Trilogy
Moz Bar | | Trilogy1 -
Duplicate Page Content Report on MOZ
Hi, I am just wondering as to the accuracy of this report - does it pick up all the duplicate on page content? Or is there a limit? We have an ecommerce store with a lot of copied and pasted descriptions - just wondering if there is a limit on how much the moz crawler picks up? In other words, once we fix what MOZ has detected, will there be more detected because it is limited to display say up to 200?? Hope you understand what I mean. Thanks
Moz Bar | | bjs20100