All Collections
Filter Options
How to Apply Custom Filters Within Google Analytics 4
How to Apply Custom Filters Within Google Analytics 4

Read this article to get insight into how you can filter your existing widgets for GA4

Rad Basta avatar
Written by Rad Basta
Updated over a week ago

Reportz offers you a way to quickly add some of the most standard metrics using our predefined widgets, but if you need something more specific you can use custom filters by following these easy steps.

Click on Add Data Widget and select GA4 as Integration.

After that, select your analytics account.

In the second step, select your Account, Property, and choose your Widget.

In our example, we will use a Custom widget, and select our Dimension (Session Default Channel Group) and Metrics (Sessions and Average Session Duration).

Below the Widget field, there is a Custom Filter field. Here we can filter our data using Google Analytics 4 API.

For example, we would like to present only Organic Search data with Session default channel group as the Dimension, and Sessions and Avg. Session Duration as the Metrics. We can do this by filtering the Session default channel to exact match Organic Search (type sessionDefaultChannelGroup==Organic Search in the custom filter field).

See screenshots below:

In the third step, you can add the widget title and description, choose widget size, type, etc. After you hit Submit on the final step, the widget will show only Organic Search results.

Pro-tip: If you are ever unsure what the exact name of the metric/dimension is for creating your Custom Filter - you can always click on Details to flip the widget around and see more information about it:

Google Analytics 4 Operators

Here is a table with all the Google Analytics 4 operators that can be used in data Filtering.

Reportz Custom filters also allow you to combine multiple filters for GA4 using AND and OR logic statements.

OR Operator

The OR operator is defined using a comma (,). It takes precedence over the AND operator and may NOT be used to combine dimensions and metrics in the same expression.

OR Operator Examples:

Country is either (United States OR Canada):
​country==United States,country==Canada

AND Operator

The AND operator is defined using a semi-colon (;). It is preceded by the OR operator and may NOT be used to combine dimensions and metrics in the same expression.

AND Operator Examples:

Country is United States AND the browser is Firefox:
​country==United States;browser==Firefox
​
Country is United States AND language does not start with 'en':
​country==United States;language!~^en.*

Dimensions and Metrics Grouping

Dimensions and Metrics Filters should be grouped and separated with :::

For example:

browser==Firefox;country==United States:::sessions>>10;screenPageViews>>20

*Note: If you are using the AND operator (;) while creating a filter that contains both dimensions and metrics, you are not able to combine it with the OR (,) operator. These two operators can not be combined in the same expression.

In case you need additional help, you can always message our support team in live chat.

Happy reporting!

Did this answer your question?