Google Analytics Goal/Event/SOMETHING to show only Wordpress "Posts", not pages, etc
-
Hi all,
Our site is build on Wordpress and formerly the post URL's had the typical date format at the beginning. This made it easy for me to look at, for example, all search traffic to the blog. I would just view URL's containing /2014/ and /2015/ and boom.
We have since removed the dates from the URL's with proper redirects etc, which is great, but now I can't figure out a way to look at ONLY the blog in GA. I like to track a KPI of 'search visits to blog posts' and I can't figure out how to now.
Can I set up a GA event that only fires when the post type template for blog posts loads? Some other solution? I'm lost here, and there's gotta be a good way to do it...
-
This is exactly what I was hoping would be possible. Thanks for pointing me in the right direction.
-
There's a couple of approaches, but I think the content grouping feature is your best bet. Here's the official overview page: https://support.google.com/analytics/answer/2853423?hl=en
Essentially, you'll be firing code on that page template that tells GA to add the page to a specific content grouping OR you can tell GA to dynamically assign content grouping based upon a full or partial URL, or page title. In this scenario, I think the first option is more likely. The full instructions are here: https://support.google.com/analytics/answer/2853546?hl=en. Essentially, on blog pages, you'd want to fire your normal GA script, with the bold line below added:
This is going to be easier with Google Tag Manager if you're able to do that, but if not, hard-coding into the site will work as well - you'll probably have to create a header-blog.php file in your theme and use that header in your blog instead of your normal one. To my knowledge, Yoast GA doesn't support this yet, but there is a ticket for it at https://github.com/Yoast/google-analytics-for-wordpress/issues/26.
Content groupings aren't historical, so you'll also want to set up a "Blog" segment that includes any of your old parameters (eg 2015 in the URL), as well as the new parameters (content grouping = blog). This should make historical analysis easier.
I don't want to drone on for 10 more paragraphs, so check out those resources and let me know if you have more questions on implementation.
-
I was thinking about this some more after I posted last night. If your site is organized into sections with subpages, then you don't have to create a filter for every one. For example, if you exclude pages containing http://mysite.com/services/, then you would get rid of not only that page, but http://mysite.com/services/service1, http://mysite.com/services/service2, etc.
(And if your site is not organized in that fashion, you might want to look into adjusting it, as such a structure would likely help your SEO.)
-
Have a ton of pages, but this could be the answer if there's not a better way. Thanks for the response.
-
One idea, which would only work if you don't have an overwhelming number of pages, would be to make a series of Exclude Filters in the pages report. (https://support.google.com/analytics/answer/1034832?hl=en) You could then save the set of filters with the "Add to dashboard" feature (http://www.blastam.com/blog/index.php/2010/09/google-analytics-tips-save-filtered-reports).
Hope that helps,
Ira
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
-
Has Google Analytics Funnel Visualisation changed / stopped working?
Yesterday my funnel visualisation tab in the updated GA interface was showing data flow. However today there is nothing showing in the graphical element despite showing some goal completion figures as a headline. Have they stopped doing up to the minute visualisation in favour of delayed results? Anyone else experiencing similar? Thanks in advance Tim
Reporting & Analytics | | TimHolmes0 -
Google Analytics to sub domains
Hi, I have a site xyz.com and two separate sites on sub domains xyz.com/abc and xyz.com/def. What's the best way to go about with GA such that I can get all the data in the same place. Should I use the GA code for xyz.com on sub domains as well? Or should I create separate profiles?
Reporting & Analytics | | mayanksaxena0 -
E-commerce data import Google Analytics
Hi there, Since a few weeks we have started a cooperation with a big online wholesale company which now sells our products. I want to import simple E-commerce data: amount of transactions and revenue. More detailed data such as amount of products, name of products, etc. is not necessary in the first place. Now I discovered the 'data import' functionality in Google Analytics but I can't find any suitable option for E-commerce data import. The data from the wholesale company is gathered in a nice export in a separate system, so there should be a way ti import this data into Analytics. Could anybody help me with this? Any advice is welcome! Thanks in advance.
Reporting & Analytics | | MarcelMoz
Marcel0 -
Dip in traffic from Pune for our sites in Google Analytics
Hi, We have noticed dip in traffic from Pune after 6th May'14 in our Google Analytics account for few of our sites. Did anyone noticed the same for your site. Kindly let me know if you have any idea. Thank and Regards
Reporting & Analytics | | vivekrathore0 -
Google Analytics subdomain ecommerce tracking flatlines :-(
Buongiorno from 19 degrees C wetherby UK 🙂 This website http://www.philpotts.co.uk/ contains a shop sub domian @ http://shop.philpotts.co.uk/. I configured the site Ga analytics code to include the subdomain (see below code). I had to do this as i was getting refferal data from the actuall subdomain. But after following the instructions on p117 of cutroni's ga book things have gone wrong, mainly now eCommerce data has dissapeared 😞 So my question is please: "Why has installing the GA code above caused eCommerce tracking to suddenly go dead?" Grazie tanto,
Reporting & Analytics | | Nightwing
David0 -
Google URL Builder Extension showing up as indexed pages.
Hello, I was reviewing my PRO member campaign report. I see that I am getting warnings for too long of URLs. However, these URLs are my website URL with the Google URL builder tracking code that I set up for my marketing campaings. Why are these being indexed? For example: www.website.com/?utm_source=Oct+Newsletter&utm_medium=e.... Thank you, Kristen
Reporting & Analytics | | KLFeichtner0 -
Google Analytics Options
A couple of months ago, I read about a new web stats application that is real time but more importantly let's you track user actions on a page (i.e. which buttons were clicked for example). This information would obviously be very helpful in continuing to improve site performance. Anyone have suggestions or know the name of this application? I do not mind paying but am not looking for an enterprise class application.
Reporting & Analytics | | Mont0 -
Google vs Bing/Yahoo SERP results?
I see large differences in Google and Bing/Yahoo SERP results for many keywords. Google shows many of our primary keywords in their top ten, while Bing/Yahoo rank the same one 40-50 or above. Do you have any insight on their differences that might account for this variation? We are legitimate, long time, white hatters at a small manufacturer that is one of the leaders in our industry. The only thing I can think of that might describe this issue is PPC advertising. Their algorithms wouldn't be that inconsistent would they? (We do much more paid advertising on Google) But generally this should have no affect, right? Thanks, George...
Reporting & Analytics | | rhawk0