Static sites
Static sites, whether hand-written HTML or the output of a static site generator, are the simplest case and work out of the box. Paste the snippet into your shared layout or template so it lands on every page:
<!doctype html><html lang="en"> <head> <meta charset="utf-8" /> <title>My site</title> <script src="https://cdn.analytics.canarycoders.es/lytics.js" data-domain="myapp.com" defer></script> </head> <body> ... </body></html>Each full page load fires one page_view (path + query string, no hash). Same-origin link clicks are tracked automatically; external links are deliberately left untracked. There is no client-side router to patch, so this is the entire integration.
Related
Section titled “Related”Framework integrationsWhere the tag goes in Vite, Next.js, Astro, and TanStack Start.
Script referenceEvery attribute the snippet reads.