Install
Install AnalyticFast on your website
Add your public website in AnalyticFast, choose its timezone and reporting currency, then copy its Site ID. Use exactly one installation method per website. The public Site ID is not a secret or a server API credential.
Plain HTML: one deferred script
For a website with a shared HTML head, paste this once before its closing head tag. Replace the placeholder with your Site ID. The examples use the hosted tracking origin; use the origin shown in your own settings if it differs.
<script defer data-website-id="YOUR_SITE_ID" src="https://t.analyticfast.com/js/script.js"></script>
Choose your platform
- Next.js — Use Next.js Script in a shared layout so the tracker loads after the page becomes interactive. You do not need to install a browser SDK to use this method.
- WordPress — Use the repository’s WordPress plugin to enqueue one deferred tracker. It has a settings page for the public Site ID and tracking origin; it does not need a payment API key.
- Shopify — A theme installation measures the Shopify storefront. Treat checkout and payment confirmation as separate surfaces rather than assuming that editing a theme covers the entire purchase flow.
- Webflow — Use Webflow’s site-wide Head code field so your published pages share the same tracker. Your Webflow plan must provide custom-code access.
- Framer — Framer can install the tracker through a site-wide custom-code entry. Use one initial load; AnalyticFast already observes navigation between routes.
- Wix — Wix’s dashboard Custom Code feature is the right surface for site-wide tracking. An HTML embed inside a page is not equivalent: it runs in an iframe.
- Squarespace — The site-wide Header field in Squarespace Code Injection adds the tracker to ordinary site pages. A page code block or order-confirmation snippet covers a different surface.
- Ghost — Ghost’s Site Header injection places the tracker on the site without editing a theme. Use the site-wide setting so posts and index pages share the same installation.
- Lovable — Ask Lovable to inspect the project before installing one tracker in its shared entry point. The plain script avoids assuming that an npm package is published or that every generated project uses the same layout.
- Google Tag Manager — The site-specific GTM template loads a public helper that attaches the Site ID to the tracker. The template needs no API key and is imported locally into your Web container.
- npm browser SDK — The repository contains a small browser package at packages/analyticfast. Its manifest is currently private; this guide does not claim a public npm release. The plain script is the available installation path when you do not have a reviewed local package build.
Verify the published website
- Replace
YOUR_SITE_IDwith the ID for this website, then open its public domain in a normal browser. A builder preview, localhost, webdriver or a visit with?ml_ignore=truemay be ignored. - In browser Network tools, check
https://t.analyticfast.com/js/script.jsand the request to/api/event. A downloaded script or a successful HTTP response alone does not prove that an event was accepted. - Use Verify installation in AnalyticFast and check the last received event. If none arrives, check the Site ID, allowed hostname, consent configuration, duplicate installations and any blocker. Domain ownership verification is a separate step.
If your site has a Content Security Policy, allow https://t.analyticfast.com in both script-src and connect-src. Do not put tokens, customer email addresses or private keys in the snippet, URLs or goal properties.
Connect revenue after visits work
A pageview confirms tracking, not a payment. Use your provider’s revenue guide to configure signed delivery and forward visitor IDs through checkout metadata. Keep production and sandbox analytics on separate sites.
Add your website to get its Site ID and installation checklist. Once visits arrive, connect your payment provider.
Questions, answered.
How many snippets should I install?
Use one method: plain script, framework component, plugin or GTM tag. Combining methods can produce duplicate tracking or conflicting Site IDs. Remove the old method before enabling a new one.
Does installing the script also record purchase revenue?
No. It records visits and goals. Connect a supported payment webhook and pass visitor/session IDs into checkout metadata to connect verified payments with traffic. A Buy click or thank-you pageview is not payment confirmation.
Does Verify installation also prove domain ownership?
No. An accepted event shows that tracking was received. Domain ownership verification is a separate check. Configure the intended production hostname and verify additional domains before using them.