Skip to main content

Why is the Leadfeeder tracking script blocked on my site?

The tracking script doesn't fire on your site because your content security policy blocks it.

Written by Ruthie Keith

If the tracking script is on your site but doesn't fire, your Content Security Policy (CSP) is probably blocking it. Add Leadfeeder's domains to your CSP to fix it.

This article is technical. If you don't manage your website's code, forward it to your web or technical team.

How to tell if your CSP is blocking the script

Use the Network tab in your browser to check whether the script fires. How to check the Leadfeeder tracking script is working shows how. A working script shows a 200 status:
​

If you search for "lftracker" and see the status (blocked:csp), your CSP is blocking the script:
​

The script can also load and then get blocked, as below. This stops the tracking script too, so check your CSP:
​


​

How to fix it

Your team sets the CSP manually, through a security tool, or with a WordPress plugin. It tells browsers which scripts can load on your site, to keep out malicious ones. You can keep your CSP and still use the tracking script:

  • For a default CSP, add *.lfeeder.com and *.leadfeeder.com to your default-src rules. For narrower rules, add sc.lfeeder.com and lftracker.leadfeeder.com.

  • If your rules include img-src and script-src, add *.lfeeder.com and *.leadfeeder.com to those as well.

Every website is different, so your web team may need to adjust these steps for your setup.
​
--

Still not working? Contact our support team via chat or at support@leadfeeder.com. Please include your account ID, the URL where the issue happens, and a screenshot, so we can help you faster.

Did this answer your question?