Block IP addresses
If you want Clarity to stop tracking certain IP addresses, you can add them to a blocklist. This excludes internal IPs such that related data isn't added to data gathered from your site's visitors.
- Dashboard: Site visitors on the list won't contribute to the tracked metrics.
- Recordings: No sessions from visitors on the list are recorded.
- Heatmaps: Site visitors on the list won't have their activity included on click maps or scroll maps.
Note
- Clarity only supports IPv4 addresses. We do not support IPv6 or dynamic IP addresses (for example, VPN). However, we couldn't block IP addresses if the user has both IPv4 and IPv6 as its non-deterministic.
- Mobile devices generally don't have a stable IP so they can't be used for IP blocking.
Block an IP address from tracking
Note
To set up IP exclusion, you need to be an administrator for your project. If you aren't, you can see which IP addresses are blocked, but you can't change anything.
Step 1
Go to Clarity > Settings > IP blocking, and select Block IP address.
Step 2
On the Block IP address screen, make your selections and then select Block.
- Name: Enter a friendly name to identify the IP address.
- Block my current IP: Check the box if you want to exclude your IP address.
- IP address: Enter the IP address.
Tip
You can also block a range of IP addresses. See the next section for details.
Once you've entered one or more IP addresses, each one is displayed in a list on the IP blocking page.
Note
You may need to wait about 15 minutes for the changes to come into effect.
Block a range of IP addresses
If you want to block a whole range of IP addresses, you don't need to enter them one by one.
Step 1
Go to Clarity > Settings > IP blocking, and select Block IP address.
Step 2
On the Block IP address screen, make your selections and select Add.
- Name: Enter a friendly name to identify the range of IP addresses.
- Block my current IP: Check the box if you want to exclude your IP address.
- IP address: Enter a set of specific IP addresses you would like to block. If you want to block of range of contiguous IP addresses, you can specify them individually. However, you can also use the CIDR range of the form
<Ip-address>/<prefix-length>
to define a set of IP addresses. Use a slash after the first address followed by the end address. For example, specify the CIDR range69.89.31.0/24
to block the range of IP addresses from69.89.31.0
to69.89.31.255
.
Tip
For more information on CIDR ranges, visit Classless Inter-Domain Routing.
Stop blocking an IP address
Step 1
Go to Clarity > Settings > IP blocking, and select the
icon to the right of the IP address you want to unblock.
Step 2
On the Unblock this IP screen, select Remove.
Verify that an IP address is blocked
You can verify that an IP address is blocked if you visit the page from that IP address.
Step 1
Browsing with a blocked IP address, go to the webpage you want to verify.
Step 2
Open the JavaScript console of your browser and look for a message.
A message is displayed at the top of the console: "Data from this session isn’t being collected by Microsoft Clarity due to your configured project settings."
Note
You can find the JavaScript console in Edge or Chrome from your browser's main menu: More Tools > Developer tools.
FAQ
For more answers, refer to FAQ.