Bypass content blockers
Serve the tracker and event endpoint through first-party paths on the tracked site.
Proxy both collection paths through your site’s domain and give them application-specific names.
-
Set matching custom paths in the Supermetry environment, then restart with plain
supermetry.Terminal window export SUPERMETRY_TRACKER_PATH=/insights/client.jsexport SUPERMETRY_EVENT_PATH=/insights/collectsupermetryBoth values must start with
/. Per-site scripts use the tracker path’s directory, for example/insights/YOUR_SITE_ID.js. -
Proxy that directory from the tracked site to Supermetry. For Caddy:
example.com {handle /insights/* {reverse_proxy https://analytics.example.com}} -
Load the generated per-site script through the tracked domain.
<script defer src="https://example.com/insights/YOUR_SITE_ID.js"></script>
The generated script derives the custom event path from its own origin, so events go to https://example.com/insights/collect through the same proxy.
What you should see: the script and event request both use example.com, and the visit appears in Realtime.