Mike Ginley

Google Looker Studio Drop-down Filter By Sections Of Site

Share Article!

In This Post

TL;DR




Google Data Studio is one of my favorite tools. It has automated tedious reporting and has allowed me to focus more time on interpreting data and optimizing sites. This tool is pretty limitless and I am always looking for additional ways to beef up my reports. A new feature I found was creating a custom drop-down filter by the section of the site. This allows easy filtering by whatever areas of the site I want.

You could easily just use an input box and search by URL slug or create a regex, but this way only needs that once and then you can always select the section you want to check out.

Google-Data-Studio-Drop-Down-Filter

Steps to Create Custom Google Data Studio Drop-Down Filter

This Free Google Data Studio Template is set up with a filter for you to see how it works

  1. Either use one of your already existing data studio reports or make a copy from the link above.
  2. While editing, under Resource in the top navigation, select Manage Added Data Sources.
  3. Edit whatever data source you are looking to filter.
  4. Add A Field in the top right.
  5. Create a Field Name in the top left (I chose Site Section) but you can probably come up with something better than that 🙂
  6. Add the code below and update it according to the URLs you want to include:

CASE
WHEN REGEXP_MATCH(Landing Page, “(?i).*/blog/.*”)THEN “Blog
WHEN REGEXP_MATCH(Landing Page, “(?i).*/what-i-do/.*”)THEN “Services
WHEN REGEXP_MATCH(Landing Page, “(?i).*/who-i-am/.*”)THEN “About

END

  1. Here is a Google Sheet with the formula set up, just add the Landing Page URL Slug and the Name of the filter in the corresponding columns
  2. Click Update in the bottom right.
  3. Refresh your browser for the filter to show in the dimension options.
  4. Add a Drop-down List Filter Control from the secondary nav
  5. Select your new filter based on what you named it.

You should now be able to filter by the sections you set up in the filter above. If you want multiple page types under the same filter you can either set them up as a regex or have different line items for each URL type with the same name. For example, if I wanted Blog, News and Insights to be under the same filter, I would have a line for each of those URLs and they would all have the same name in the drop-down selection.

NOTE: The ‘Null’ selection is any landing page that is not accounted for in the filters you create.

If you have any questions or issues with the template, please reach out to me on social media!

Helpful Google Data Studio Resources

Some SEO Wisdom:

SEO isn’t a stand-alone tool. Use it in everything you do. This data should be used for all marketing whether it’s SEOPPC, Email or Social. Whoever is working on these channels can easily come to this dashboard and see what is and is not working. What pages are moving the needle? Keep pushing those!

Recent Articles

Popular Articles