- Exclude yourself or internal employees from experiment results
- Set up IP filtering on your Optimizely project
- Filter multiple IPs or an IP range
IP filtering allows you to exclude certain IP ranges from showing up in your experiment results. This is also how you can exclude yourself or your company from experiment results.
IP Filtering will not prevent you from seeing an experiment; it will simply make sure to filter you and your actions out from the Results page. To exclude IP ranges from being included in experiments, see our article on IP Address Audience conditions.
How does IP filtering work?
IP filtering is done at the project level, so if you have a staging server and a live page it might make sense to keep them in separate projects so that you don't have to keep turning IP filtering on and off.
To access IP Filtering from the Home page, click Settings and then Privacy. In the field under Filter these IP addresses out of results, enter the IP(s) that you don't want to be counted in your experiment results.
If you use a regular expression to match multiple IPs, your IP Filtering regex should match the full IP address to work properly. Partial matches will not work. If you've turned on IP Anonymization as well, the IP Filtering regex should match the last octet as 0 (zero).
The IP filtering option lets you exclude as many IPs as necessary in a single line. Bear in mind that you should be using your public IP address. Also keep in mind that Optimizely’s IP Filter has a max character limit of 1500.
The IP filter limit was formerly 500 characters but has now been raised to 1500 characters.
Setting up Multiple IPs to be Filtered
If you're filtering just one IP address, you can enter it normally.
However, if you need to enter multiple IPs, you can also use regular expressions (regEx). To separate multiple IP addresses, add a vertical pipe (this character:|), between them. Note that you're not required to use any special characters if you're just entering a single address.
An example of an IP filter for two IP addresses would be: ^34\.1\.213\.45$|^90\.100\.5\.73$
Any additional IPs would also need a | between them to separate them. There is no limit on the number of IP addresses you can add; you’re only limited by the 1500 character limit.
Setting up an IP Filter Range
Optimizely supports regEx, so we can use it to create an IP range easily without having to enter every IP address in it.
For example, if you wanted to filter out the IP range 126.96.36.199 to 188.8.131.52 you would want to use a regEx range instead of writing in every single IP address for that range. Using regEx this would end up looking like this: ^206\.23\.100\.([5-9][0-9]|1([0-4][0-9]|50))$
If regEx is a bit out of your wheelhouse, you can use this handy tool to help you generate these regEx formatted iP ranges.