There have been quite a few questions on this forum about Google Analytics filters and segments, with quite a few misconceptions.
This short article is meant to be a basic primer on Google Analytics filters and segments.
[more advanced articles on both topics will be made available shortly]
Filters and segments in Google Analytics are two techniques used to select data to be shown in reports.
They work very differently and it is important to know the difference between the two techniques before configuring and using them.
Filters change the way data is collected in a Google Analytics view. They are used primarily to include or exclude data from a view but advanced uses include sophisticated search/replace operations, rewriting and formatting of data fields.
Once that filtered data is collected, it is “set in stone” and then processed into the reports you access via the reporting interface.
/!\ Because data in Google Analytics cannot be (re-)processed retroactively (save in very rare cases), a best practice is to keep a “raw data” unfiltered view in your Google Analytics property. That raw data view can be used as a "canary" to identify faults/bugs in your data collection or site sections that can be filtered out into their own view.
Another best practice is to add an annotation in your view to point out when a specific filter was applied; this helps your team members know of important changes to your view.
It should be noted that filters can only be used with Modify access rights and that filters can be re-used on different views in the account or property. This means that you may not be able to set and use filters. Also, filters are executed in a specific order so pay attention to your filter conditions.
Further caveats: knowing regular expressions can come in handy but don't worry too much, basic filters are provided with "wizard"-style settings.
For reference on filters, please read: https://support.google.com/analytics/answer/1033162?hl=en
Segments are a way to isolate a sub-set of your visitors (users) or visits (sessions) based on behavioural parameters such as geography, visit recency or conversion abandonment for instance. Once applied, a segment only shows the part of the traffic that matches the specified user or session behaviour.
Segments work differently than filters in that they apply to all existing data in your view. They work in read-only mode so you can create as many segments without risking to destroy/corrupt data going forward.
A great test segment is to select the built-in (system) segment “Non-bounced sessions” and compare it to the default “All sessions” segment for insights on actual time spent on site and site engagement.
You can create up to 100 segments per user account so try them out and experiment!
For reference on segments; please read: https://support.google.com/analytics/answer/3123951?hl=en
As you noticed from these explanations, filters should be used for data preparation purposes, whereas segments are meant as a way to focus on different session or user behaviours to highlight patterns and insights. Unless you are a power user and/or admin, just use segments for reporting and analysis.
15+ years in web/digital analytics consulting, evangelist for Hub'Scan, an analytics tag quality assurance solution.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.