Ad blockers and the proxy host
Why some visits never reach any analytics tool, how to tell how many you are losing, and how to serve the script first-party.
Content blockers hide requests to known analytics hostnames. Statsy is not an ad network and sets no third-party cookies, but the blocklists are based on hostnames, not on behaviour, so a share of visits simply never arrives. Every analytics tool has the same problem.
Confirming it is a blocker
Open your site in a private window with extensions disabled and watch Live. If you appear there but not in your normal browser, a blocker is the cause. In your normal browser the request to /api/collect is missing from the Network tab entirely, rather than failing.
Note. A blocked request looks identical to a script that never ran. Rule out the simpler causes in Script installed but no data before assuming blocking.
Serve the script from your own hostname
The fix is to make the script first-party. Set a Proxy host in Site settings › Tracking — something like s.example.com — and point it at Statsy with a CNAME record.
s.example.com. CNAME proxy.statsy.co.A certificate is issued automatically once the record resolves, and the install snippet changes to load the script from your hostname. Requests go to your domain, so hostname blocklists have nothing to match. Full instructions are in Serving the script from your own domain.
When the proxy host does not work
| Symptom | Cause |
|---|---|
| The script URL returns a certificate error or 404 | The CNAME does not resolve yet. DNS changes can take a while; check the record, then wait and retry. |
| The certificate never appears | The hostname is proxied by your own CDN. Point the record straight at proxy.statsy.co with proxying turned off, so the certificate can be issued. |
| Any other path on that hostname returns 404 | That is intended. Only the tracking endpoints are served there; it is not a general proxy for your site. |
What to expect afterwards
Recovery varies by audience. A developer-heavy audience blocks far more than a general consumer one, so the jump after moving to a proxy host is bigger for some sites than others. Compare the week before and after rather than a single day.
Comparing with other tools
Statsy will rarely match another analytics tool exactly, and a difference is not proof of a problem. Different tools count sessions differently, filter bots differently, and are blocked at different rates. Statsy reports bot traffic separately rather than folding it into visitors, which alone can explain a gap.
Last updated · Markdown version