Plain HTML install
If your site is a set of .html files (with or without a static generator like Hugo, Eleventy, Astro), this is the most direct install.
Steps
- Open
index.html(and any other file you want to track —about.html,contact.html, etc., or a shared partial if you have one). - Paste the snippet right before the closing
</head>tag:
<script defer src="https://wheremyflow.com/w.js" data-site="YOUR_SITE_ID"></script>
- Save and deploy.
If you use a static site generator
- Hugo: add the snippet in
layouts/_default/baseof.htmlorlayouts/partials/head.html. - Eleventy: in your main layout (
_includes/base.njkor equivalent). - Astro: in the
<head>of your layout file (src/layouts/Layout.astro). - Jekyll: in
_includes/head.html. - Hexo / Pelican / Zola: in your theme's base template.
These generators all share the same principle: one layout file defines the shared <head> — that's where the snippet goes.
Server-rendered pages (PHP, ASP.NET, JSP…)
Same idea: the snippet goes in the <head> of your shared template. If you have several templates (say one for public pages and one for the blog), drop it into each.