Tracking code

This JavaScript snippset is responible for collecting user statistics. It needs to be added to all html pages you want to track. For example inside the <head> section.

<script> // Simple Web Analytics tracking code
if (!sessionStorage.getItem("_swa") && document.referrer.indexOf(location.protocol + "//" + location.host) !== 0) {
    fetch("https://simple-web-analytics.com/track?" + new URLSearchParams({
        referrer: document.referrer,
        screen: screen.width + "x" + screen.height,
        site: "USERNAME",
        utcoffset: 0}))}
sessionStorage.setItem("_swa", "1");