Analytics
4.6K members online now
4.6K members online now
Ask questions about filter set-up and issues with using filters in Google Analytics reports
 
Guide Me
star_border
Reply

Setting a filter for meta tag in reports

Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

Hi, I'm trying to set up a filter to track views of a certain set of pages, but the problem is that the only feature that distinguishes these pages from others on our website is a meta tag. The page url and title unfortunately contain nothing unique to the pages I want to track. Is there a way to set a filter to track only pages with a certain term in the meta tags?

 

For example, the tag I need to track looks like this:

<meta name="store:section" content="PURPLE DAISIES" />

 

1 Expert replyverified_user
1 ACCEPTED SOLUTION

Accepted Solutions
Marked as Best Answer.
Solution
Accepted by topic author Company of B
July

Setting a filter for meta tag in reports

Rising Star
# 2
Rising Star

Hi,

 

Well you have a couple of options.

 

If you do not need a separate view you can use content grouping which will let you define any group of pages.  If you know all the pages you want to track you can enter them in the page group setting.

 

That said, it sounds like you do want a view filter in which case you'll need to use custom dimensions.  Have a programmer dynamically set the custom dimension in the Google Analytics Tracking Code whenever the meta tag is present.  Alternatively this could also be done via code inserted via Google Tag Manager or by using data import.  Once you have the custom dimensions tracking, you can create view filters based upon them but you must create the filter in the view tree and not in the account tree to use custom dimensions ( I have no idea why  Smiley Happy ).

 

Resources:

 

Content Grouping

https://support.google.com/analytics/answer/2853423?hl=en

 

Custom Dimensions

https://support.google.com/analytics/answer/2709828

 

Data Import

https://support.google.com/analytics/answer/3191589?hl=en

 

 

Best,

 

Theo Bennett

Analytics Evangelist at MoreVisibility | Contact Me
Connect on LinkedIn

View solution in original post

Marked as Best Answer.
Solution
Accepted by topic author Company of B
July

Setting a filter for meta tag in reports

Rising Star
# 2
Rising Star

Hi,

 

Well you have a couple of options.

 

If you do not need a separate view you can use content grouping which will let you define any group of pages.  If you know all the pages you want to track you can enter them in the page group setting.

 

That said, it sounds like you do want a view filter in which case you'll need to use custom dimensions.  Have a programmer dynamically set the custom dimension in the Google Analytics Tracking Code whenever the meta tag is present.  Alternatively this could also be done via code inserted via Google Tag Manager or by using data import.  Once you have the custom dimensions tracking, you can create view filters based upon them but you must create the filter in the view tree and not in the account tree to use custom dimensions ( I have no idea why  Smiley Happy ).

 

Resources:

 

Content Grouping

https://support.google.com/analytics/answer/2853423?hl=en

 

Custom Dimensions

https://support.google.com/analytics/answer/2709828

 

Data Import

https://support.google.com/analytics/answer/3191589?hl=en

 

 

Best,

 

Theo Bennett

Analytics Evangelist at MoreVisibility | Contact Me
Connect on LinkedIn

Setting a filter for meta tag in reports

Rising Star
# 3
Rising Star

David, did you reply in the wrong thread?  This is an old post from last July about filtering in Google Analytics.  If you are the original poster "Company of B" and this was a Data Studio question - then it was posted in the wrong forum.  If you just posted on the wrong thread and you need to do something similar in data studio you and you want to accomplish this in sheets you can do it using the lookup function in sheets to tie together your page data from GA with the meta values in a another sheet.

 

 

Hope that helps.

 

Cheers,

 

Theo

Analytics Evangelist at MoreVisibility | Contact Me
Connect on LinkedIn