Partilhar via


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 don't contribute to the tracked metrics.
  • Recordings: No sessions from visitors on the list are recorded.
  • Heatmaps: Site visitors on the list are excluded from having 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

Select a Clarity project. Go to Settings > IP blocking, and select Block IP address.

IP blocking.

Step 2

Tip

You can also block a range of IP addresses. See the next section for details.

On the pop-up screen, make your selections and select Add.

  • Name: Enter a friendly name to identify the IP address.
  • Block my current IP: Check the box to block your IP address.
  • IP address: Enter an IP address or multiple IP addresses separated by a ,.

Add an IP address to block.

Once you enter one or more IP addresses, each one is displayed on the IP blocking page.

List of blocked IP addresses.

Note

Wait about 15 minutes for the changes to come into effect.

Block a range of IP addresses

Follow the steps to block a range of IP addresses:

Step 1

Select a Clarity project. Go to Settings > IP blocking, and select Block IP address.

IP blocking addresses.

Step 2

On the pop-up 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 to block your IP address.
  • IP address: You can use the CIDR notation <Ip-address>/<prefix-length> to denote a range of IP addresses. To define the range, append a slash after the initial address, followed by the end address. For example, specify the CIDR range 69.89.31.0/24 to block the range of IP addresses from 69.89.31.0 to 69.89.31.255.

Add a range of IP addresses to block.

For more information on CIDR ranges, see Classless Inter-Domain Routing.

Stop blocking an IP address

Step 1

Select a Clarity project. Go to Settings > IP blocking, and select the icon next to the IP address you want to unblock.

Step 2

On the pop-up screen, select Remove.

Select inspect.

Verify if an IP address is blocked for a webpage

Note

The following steps are applicable only to websites. 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.

Verify a blocked IP.

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.

Visit Clarity