Analytics
2.7K members online now
2.7K members online now
Dive into multiple domain (Cross/Sub) tracking, implementing Ecommerce and Enhanced Ecommerce, setting up Event tracking, and Universal Analytics code.
 
Guide Me
star_border
Reply

track subdomain page

Follower ✭ ✭ ☆
# 1
Follower ✭ ✭ ☆

Hi everyone!

Hope you can help. 

I need to track users going to subdomain page, which has same path as a page inside the domain. 

ie. I need to track visitors going to sub.example.com/abc/ (as a goal completion), but I also have a page which is example.com/abc/ for which I need to exclude traffic count as goal completion. 
Can you please help me figure out how I can do that
Thanks.

Eugenio

1 Expert replyverified_user

Re: track subdomain page

Top Contributor
# 2
Top Contributor
Hi Eugenio,

One possible solution would be to create a Filter that modifies your GA data so that moving forward the full page URL is displayed in your reports.

To match your example after creating this filter, instead of seeing /abc/ in your reports you would see sub.example.com/abc/ and example.com/abc/ which would allow you to create your subdomain specific destination goal.

This Filter can be created in your Admin under View > Filter > +ADD Filter and would need to be configured as follows:

Filter type: Custom > Advanced
Field A: Hostname
Extract A: (.*)
Field B: Request URI
Extract B: (.*)
Output to: Request URI
Constructor: $A1$B1

A few things to keep in mind:
- Filters only effect future data and cannot be retroactively applied
- You should always try out Filters in a Test view before using them in your Reporting/Main view
- Your Goal setup with need to be modified to reflect the new full URL reporting. Following your example, the goal destination would now be sub.example.com/abc/

Let me know if you have any other questions.

Cheers,
JD