TrafficDam Docs

Filter by Code

Once your domain is verified, you can generate your protection snippet.

How to use Filter by Code:

  1. Go to Create Filter > Filter by Code.
  2. Configure your filters (Device, Country, VPN detection).
  3. Copy the generated JS Snippet.
  4. Paste the snippet at the Very Top of your <head> tag, preferably above all ad scripts (AdSense, Adsterra, etc.).

When an invalid user hits your site, the script executes before the page renders and redirects them to a safe URL, effectively masking your real ads from bots.

Still have questions?

Our engineering team is here to help you integrate and scale.

Contact Support