Skip to content

Hugo

Finding your Site ID

Log in at dash.botfighter.dev → your Site ID is shown at the top of the dashboard.

  1. In your Hugo project, open one of these files (whichever your theme uses):

    • layouts/partials/footer.html
    • layouts/_default/baseof.html
  2. Find the closing </body> tag and paste the snippet immediately before it:

html
<script
  src="https://botfighter.dev/botfighter.js"
  data-site="YOUR-SITE-ID"
  data-api="https://api.botfighter.dev"
  data-honeypot="true"
  defer>
</script>
  1. Rebuild and deploy:
bash
hugo && <your deploy command>
  1. Visit your site and check your dashboard for the first signal.

TIP

If your theme doesn't have a layouts/partials/footer.html, copy the theme's footer partial into your project's layouts/partials/ directory and edit it there. Hugo uses your local copy over the theme's.


Need help? Check the dashboard for your live signal feed.