Google Analytics and measuring search terms to destination pages - google-analytics

Been using internal site search with Google Analytics and while I love the ability to see what my users are searching for, I am having a really hard time figuring out what search terms lead to which pages.
When I search on both the nextPagePath and searchKeyword dimensions while filtering on the search results page at the current path, the nextPagePath is always the search results page even when I know it shouldn't be (when tracking my own obscure searches). The same goes for using the searchDestinationPage dimension. I can't get any data that shows a jump from a search results page to another page on the site.
Here's a cleaned up example of my api query.
dimensions=ga:searchKeyword,ga:nextPagePath&metrics=ga:pageviews&filters=ga:previousPagePath=#dosearch
When I use the standard Analytics UI and look at the Destination Pages list under Content->Site Search->Destination pages, I only have 25 or so, all of which are just the variations on the base search-result page URL.
Do I need additional tracking code on my search results pages? Custom variables? A different query through the API?
I can see the tracking requests going out from both the search results and the pages selected from the results.
I found a couple of questions in the Analytics forums that ask this same question, but none of them had anything resembling a working solution.

I would bet you are not using the proper dimensions in the API
See https://developers.google.com/analytics/devguides/reporting/core/dimsmets/internalsearch
ga:searchDestinationPage is probably what you wanted when using ga:nextPagePath

Related

Tracking links within my site

I want to track particular links on my site to see where they come from. For example, I want to know which links on my navigation are being clicked, so if something is not being clicked I could potentially remove it.
I have been using UTM's, super easy, but results in skewed analytics data.
I looked into Google Tag Manager, but I don't want to slow down my website. I can change the site easily, so not sure if this is the best solution.
I found an article dated 2008 that says I can do this:
https://www.example.com/?from=topnav
Is that still valid? Is there a better way. I can't seem to find any information on this and assume somebody wants to acquire this information.
Thank you.
I have been using UTM's, super easy, but results in skewed analytics
data.
UTM codes are meant to track inbound traffic. Don't use them to track internal/outbound navigation, as it will seriously mess up your reporting.
I looked into Google Tag Manager, but I don't want to slow down my
website.
GTM is loading async, just like GA, so performance-wise they are equivalent.
I found an article dated 2008 that says I can do this:
https://www.example.com/?from=topnav
By default GA will not track link clicks. You can indeed add parameters to URLs and then use those to build custom reports and see which links are being clicked.
Since what you're trying to do is custom implementation, you won't find a single best answer, it's up to you to implement something that fits your needs. These are some examples:
https://analytical42.com/2017/track-internal-links-google-analytics-gtm/
https://www.gravitatedesign.com/blog/can-google-analytics-track-link-clicks/

Woocommerce Parameters Google Indexing

I'm currently using woocommerce and by chance when looking through google search console I noticed well over 15,000 pages had been indexed. Instantly raised a concern because I know I should have no more than 400 actual pages.
After looking into it, I noticed that absolutely every possible parameters "variations, grid styles, shipping methods" etc is being indexed causing what is 400 into 15,000 variations.
Does this have an affect on google ranking showing 15,000 pages when really there are only 400.
I can not find a single resource that explains whether google indexing so many variations has a positive or negative impact on google rankings.
Finally how to prevent google or any other search engines from indexing url's with parameters. I've seen advice using robot.txt but no recommendation of what standard woocommerce filters should be excluded or if that's a bad idea?
I have a feeling I am losing alot of link juice by having so many indexed pages with parameters?
WordPress by default expects that you wish to share everything because why not? Surely if you have 15,000 items that are index-able surely you'd be more mad if your site decided on a whim to hide parts of that without you knowing. It is understandable that this would be confusing though, and quite rightly it is always better to have control over which parts of your site gets seen by search engines.
Anyway there are plugins which allow you to customise which parts of a website are visible or hidden to search engines by providing a mechanism for generating an XML site map (an index of which pages should be crawl-able). A very common plugin I see people use is called Yoast SEO. Another one I have had some success with is called Google XML Sitemaps, you may find another to work better for you, but that should give an idea of what you need.
Also if you are not getting visited often by google bot then take the sitemap from one of those types of plugins and submit via the google console to help google better understand your site.

Bing Web Search shows results only for my domain

Using Bing Web Search API, I need to filter results only for my domain, example query:
https://api.cognitive.microsoft.com/bing/v7.0/search?q=site:mysite.com+myquery
But in results I received not only mysite.com results but also from sites like wikipedia and others.
How I can search result only for my domain?
Bing Custom Search not work for me because I have more than 10k transactions
Your website is probably not known or indexed by Bing. Since you use Bing Search API, not a custom indexing service or search across a sitemap.
The actual Bing website will need to be able to find your site.
Since it doesn't, this triggers the default behavior of returning as relevant as possible results.
This behavior is valid for urls such as the following:
https://api.cognitive.microsoft.com/bing/v7.0/search?q=microsoft+site:notAnIndexedWebsite.com
Formatting wise, there is multiple options, as seen here.
None of it is a problem in this case.
You can try Bing custom search if it helps (at https://www.customsearch.ai/), especially as it is now in GA. It also provides option to crawl your pages in Bing index through webmaster, if they are not crawled already. This should make sure that you get results only from your website.

Google Analytics: Goals with regular expressions are not working

I know that it might be odd, but I need your help with the google analytics set up.
Task: I need to set up brochure downloads as a goal for international students on a page https://www.cqu.edu.au/international-students/international-brochures .
In a perfect world, I would need to set up an individual goal for each type of brochure download (postgraduation, undergraduate, English courses) but I decided to start from "all brochures" to save the number of goals that I have for the view. Unfortunately, I don't have a chance to set up "events", so I have to work with goals only.
Final goal destination: Any page containing "pdf_file" in its description.
Pathway: come to International section, move to brochures, then go to brochure page (containing "pdf_file" in its description, for ex. - https://www.cqu.edu.au/__data/assets/pdf_file/0005/158540/2017-Undergraduate-International-Guide.pdf).
The problem: I tried to use regular expressions such as "^/__data/assets/pdf_file/." or ^/pdf_file/(.) and I can't see conversions in real time test.
However, nothing helped, and goals (even the page visit) still aren't tracking correctly. What am I doing wrong? And, if possible, how can I split goals across different brochure types?
Many thanks,
Kirill
You are on the right track. You just need one Goal. The problem you have is that after clicking a pdf document you are being redirected to a PDF viewer iframe. This is a PDF view "page" with no Google analytics tracking code whatsoever.If you use are using destination goals the only way this will work is by having installed the Google Analytics (GA) tracking code at the "final destination page".
One way to track pdf "views" is by creating a short url for each one, hence you will be able to track or check how many of them have views.
Another way is to create an onclick event within each link. But this is only possible if you can setup the events in GA. Creating this kind of event tracking will allow you to set up labels for each pdf's name to be able to identify or track each one of them.

Tracking displays of iframe component in Google Analytics

Site A gives their affiliates an interactive component (traffic map based on Google Maps), which they in turn put on their sites (Site B) in an iframe. The component is dynamic, doesn't change the URL of parent site, and has an id for each affiliate site.
What I would like to do is track the displays of the component. (Price of using Google Maps for the component depends on number of views).
At the moment the component is in <iframe src="http://SiteA.com/q?cp=43.520,18.910,10&cm=1"></iframe>.
I have looked at the other topics but didn't found a solution to that problem. I would really appreciate any help, I had no experience with cross-site tracking yet.
You as siteA owner want to count number of displays of iframe on other sites, correct?
The basic way to do it is logs analysis — every time your server returns page http://SiteA.com/q?cp=43.520,18.910,10&cm=1 or similar it adds an entry to your server's log files. The can be count when. There is a number of solutions for analyzing log data. Some of them opensource and free, other are paid services. For exmaple: http://awstats.sourceforge.net/
There is other ways to count it, but it's probably easiest way of all.

Resources