Do you know that you must exclude multiple IPs from Google Analytics? In case, your reply is in the negative, then you must read this article. A lot of people hire a WordPress developer or another professional to acquire a website. Most such users are advised by the developer or a marketer to integrate Google Analytics with their interfaces. This tool helps them in monitoring and measuring website traffic on a wide range of metrics. However, they need to be aware of some good practices to effectively leverage the tool. For instance, you visit your own website multiple times in a day and have not excluded your IP. Then you are accessing skewed data which will not provide much valuable insight. Let’s see how you can exclude your IPs from getting tracked by Google Analytics.
We will begin by explaining how to exclude all subnets of a specific IP. This can be done by creating view filters. In Google Analytics, filters allow you to modify the data you want to view. They can help you select only the specific subsets of traffic for tracking. Creating is a filter is easy and can be done easily through your Analytics dashboard. Go to Admin and choose Filters in the View section. Set the type for the new filter as predefined. Then using the dropdown menus below set the filter as “exclude traffic from the IP addresses that begin with”.
You will now have to enter the specific IP address you want to exclude. Let’s say your IP address is 192.168.0.x. Here x can be any number. Then you must enter 192.168.0 in the IP address field. This will exclude all the subnets of this address like 192.168.0.1, 192.168.2, etc.
You are now aware that you can set a particular IP to not to be included in Analytics tracking. Many users generate separate filters for each of the addresses they want to bar. This can be a tedious and time-consuming task especially if you own multiple systems. It will also be inefficient for marketers to build separate filters for all the different addresses they use to monitor their client’s website. In this section of our guide to exclude multiple IPs from Google Analytics, we will explain how to bar ranges of sequential IPs. You can do this by using REGEX which is a character sequence that defines a search pattern. Select Filters in the View section of your admin panel just like in the above tip.
However, this time after creating a new filter, choose the type as Custom. Then set the Filter Field as IP Address. Now let’s assume you want to block the IP range, 192.168.0.0 – 192.168.0.9. Then enter the following address in the Filter Pattern box.
Here ^ indicates the beginning and $ denotes the end of the string. \ stands for the escape character and [0-9] indicates any number from 0 to 9. Save the filter to block the IP range from Analytics monitoring.
As a website owner or marketing professional, you will need to remove multiple IPs from Analytics monitoring. In some scenarios, these addresses will neither be subnets of a specific IP or be in a sequential range. Let’s say you track your website from systems at home and workplace apart from devices like smartphones. All these devices can have different IPs which you would want to exclude. You can again use REGEX for your purpose. This will enable you to generate a string with the addresses that you want to block. For instance, your home computer’s address is 18.104.22.168 and that of your office system is 127.101.1.1.
Generate a string like the one shown below:
Access the Admin section of your Analytics profile and go to Filters in the View Section. While creating the filter choose its type as Custom. Set the Filter Field as IP Address and then enter the above string in the Filter Pattern box.
Here the vertical bar, “|” signifies OR. Save the filter to block random IPs.
You will now be able to exclude multiple IPs from Google Analytics. This will be helpful in getting accurate data which can be used to improve the website’s performance.