Only show Google Analytics for my live domain - google-analytics

In my google analytics account it is showing data from my local testing server. I've also got a fairly popular tutorial/demonstration on my site, that people copy the whole source code and put on there site without removing my google tracking code. So i'm getting info about their traffic.
I've had a look through the settings and couldn't find anything relevant. Is there some sort of filter I can apply to show more accurate results.
Thanks,
Paul

You can use an include filter.
Filter type: custom -> include
Filter field: Hostname
Filter pattern: yourdomain\.com
Case sensitive: no
Note that you can have multiple excludes filters but only one include filter per profile.
And, you should always create a different profile for filters. Keep a separate raw profile with no filters.

Related

The Google Analytics Vote For Trump Analytics Spam

We were checking newly implemented Google Analytics for our mobile app and surprisingly there are a lot of visitors from multiple countries but in actuality, we haven't released our app for any store and it's just beta between 5 main users.
After checking Google Analytics report in details we have found that it got spammed by Bot call "Trumps Bot" when something happens on your account you can see following lines in your language section.
“Secret.ɢoogle.com You are invited! Enter only with this ticket URL. Copy it. Vote for Trump!”
There are a lot of solution available to avoid this data in your reports using the filter but i was just wondering if there is any concrete solution on permanently remove this data from my reports and also is there anything we can do to avoid such data in future as its seriously affecting business strategy.
Due the tecnology used on Google Analytics the only way to eliminate this referal is using a filter, check one common point of all this hits . In this case is a hard one, because all the parameters changes , exept for the language, for a well know reason, to see the spam.
So try to use this one, in my case works
I highly recommend you read the community policy, this can be considered as off-topic question
Analytics spammers are always trying to find new ways of getting attention, and with this one, this spammer hit it big.
It is not possible to permanently remove it unless you delete the whole property. But you can create and advance segment to get a clean view.
But the most important part is blocking it so it doesn't pollutes your data. For this particular type of spam you should create a custom exclude language filter with this expression:
\s[^s]*\s|.{15,}|.|,
That expression will block any hit that doesn't use a proper language. That combined with a valid hostname filter should prevent most of the current spam and save you a lot of headaches.
If you need help, you can check this step by step guide for building these filters and creating the advanced segment to remove it from your historical data.
Here is also a related question.
Login in to Your Google Analytics account
Select ADMIN Section
Click on All Filters -- Add Filters
Give a filter name such as -- Include only website traffic
In Predefined section, select  Include Only
for more... Click Here

How to automatically filter spam referrals in google analytics

There are a lot of very good articles and answers out there that explain (in detail) why we get spam referrals messing up Analytics data. Example results: how to automatically stop spam traffic in google analytics
What I want is a definitive solution...
If you only manage one analytics account, it would not be unreasonable to manually filter suspect domains, but even this is not sustainable. If you, like me, manage over 30 accounts and counting, it gets ridiculous. What is the long term solution?
Analytics data is important for making business decisions.
Is there some service that, like antivirus software, keeps updating its 'definitions' and constantly filters spam traffic?
How can we fight back?
And how can/is it already automated in a one-click solution?
You can try these 2 options to decrease referral spam:
Option 1 - Filter bots
Mark "Bot Filtering" option on on your Google Analytics View Settings. You will need to do it to all of your views
And also create a filter to exclude referral sources. To do this, create a new filter with options:
Filter Type: Custom
Exclude
Filter Field: Campaign Source
Filter Pattern: youporn-forum.uni.me|free-share-buttons.com|Get-Free-Traffic-Now.com|event-tracking.com|darodar.com
--> Also add other spam sources that you have
You can reuse the filter to multiple views.
And its also recommended to not apply these filters in your main view. Instead, create a copy of main view and use it to analyse your data.
Its not a permanent solution (you will need to add new spam sources from time to time).
Option 2 - Segment real users
You can also create a segment to filter only users that visited at least one page (it will filter spams):
Create a new segment
Advanced > Conditions
Filter | Sessions | Include
Screen Views | per session | > | 0
Then, when you are analyzing your data, use this segment to see only real users.
Not all spammers are blocked by Google Analytics (only up to 75% of bots can be blocked by google analytics). By adopting the following steps you can automate removing referrer spam:
Go to Acquisition>all traffic >refferals and a new window will be opened which shows sources from where your website get traffic
In this step select all website who have 0 or 100 % bounce rate and copy it and make a regular expression .the method for making expression is given below
Use "\." (escaped dot) between every part of the domain and use "|" (pipe) symbol to separate every link. E.g. consider your blog hits by two spammy URLs "ads123.abc59055xxb896.comtom" and "dd54.xy789z.usjpa" then we made following resultant expression:
"ads123\.abc59055xxb896\.comtom|dd54\.xy789z\.usjpa"
if you have any trouble in making regular expression then click here to see the complete process
Select the add filter option in admin tab and select include and paste the whole expression in the expression field and click on save

Cross domain tracking - Report per domain?

I am implementing cross domain tracking for a client. We will be using Universal Analytics with Google Tag Manager.
Let's say the client has three domains: example.com, example.de and example.se. We would like to have a master account that tracks everything, but we would also like to be able to drill down and see a single domains stats. Perhaps this already exists without any customization but I have been unable to find anything on how though.
What I can see there are two ways to go about:
Create a filter that automatically appends the domain to the tracked data. So instead of /about in my view, I would get example.com/about and example.se/about. But how would this work with event tracking? Is it possible to get a report the way the client want's?
Use custom variables and dimensions. This way I could set up a variable for Domain and send in before tracking the data. But will it be sufficient to get the reports wanted?
Appreciate any help.
Thank you,
Bjorn
Hostname ist already tracked, you can set it as second dimension to break down pageviews etc. by domain (works with events, too). However that is really cumbersome and most people follow the route you have outlined in Point 1. (Google suggest that themselves in their filter documentation) - however you'd still need hostname set as second dimension to break down by domain in the events report (or you create custom reports filtered by hostname for events for each domain).
Or you create segments based on hostname (since you can compare up to for segments that would allow you to compare the overall performance and domain performance).
Plus of course you can create additional views filtered by hostname and add the domain name only in the rollup-profile for all domains.
So there are several ways to do this somehow okay-ish, but nothing really better than the solutions you already came up with yourself.

Using advanced filters - Google Analytics

A client I am working for has a requirement to use historical data in Google Analytics to present a report that shows them page views on a specific page, but only when refereed to said page from the homepage, basically like in-site ad tracking. I have discovered that I can create reports that are grouped on a user-defined variable, however I need previous data to also be included in this report, and therefore cannot simply define this inside of my Google Analytics call.
I have therefore been experimenting with Advanced filters, in an attempt to populated the user-defined field with a query-string variable. I have attached an image below illustrate my current configuration:
This configuration isn't populating the "User-Defined" field, and therefore not producing the desired results.
Any help would be appriciated.
Any filters you set will only be applied to new data, not historic.
Probably what you are after can be retrieved through the Analytics API (you can use the Query explorer for that).
Try the following:
dimensions: ga:nextPagePath
metrics: ga:uniquePageviews
filters: ga:previousPagePath=~<YOUR STARTING PAGE>;ga:nextPagePath=~page\=
sort: -ga:uniquePageviews
What the query is asking is "Which are the top pages that include 'page=' did users click on from your starting page?"

Best way to generate an automated report in Google Analytics for a specific collection of URLs

Currently using Google Analytics as a supplement to our paid tracking software, but neither of them are giving us exactly what we need.
I have a list of about 60 or so urls (out of about 1500) on the site that I wish to setup a monthly report for that can be emailed to multiple recipients. I can't seem to figure out how to create a report showing just the hits on these 60 urls, I can apply advanced filters on the content page but those disappear after a while and sometimes error out when adding too many URL's.
Is there a method I'm missing in Google Analytics to achieve this goal or am I better running an SSIS package to pull the URL's from the API and formatting a document that way?
Yeah, advanced filters are not really designed for this kind of thing.
Here are some things which may work for you:
Try setting up a new GA Profile with an Include filter to filter only the URLs that you want to report on. You can use a regular expression to identify the 60 URLs. Then these will be the only URLs tracked in that particular profile.
Try setting up an Advanced Segment to select the Pages using a very long "OR" filter.
You could set up a new GA account and log the URLs into that account with additional tracking code. This is not really recommended as the 2 accounts will share tracking cookies.
Use Excellent Analytics to pull down data into Excel for the URLs in question using the GA Export API.

Resources