StatsNGraphs
Docs Dashboard
Documentation

StatsNGraphs docs

Everything the product does today, with short step-by-step instructions. Add one script tag, then track conversions by pointing and clicking — no CSS selectors to write by hand and no cookie banner to maintain.

Getting started#

Introduction#

StatsNGraphs is a lightweight web analytics app. You install one script tag on your site and get visitors, pageviews, engagement, referrers, countries, devices, and conversion goals — without cookies, and without storing visitor IP addresses.

Three things make it different from a typical analytics tool:

Quickstart#

Five steps from a new account to your first conversion metric.

  1. Sign in at /login. You will get a one-time link by email — there is no password.
  2. Create your first site. Give it a name (for example My Blog) and a site ID (for example my-blog).
  3. Copy the tracking snippet and paste it into your site's HTML. See Install the snippet.
  4. Visit your own site once, then open the dashboard and set the range to Today. The Live counter at the top should show at least one active visitor.
  5. Track something that matters: open Event RulesVisual picker and click a button on your site. A matching goal is created automatically.
Tip

Traffic from localhost and 127.0.0.1 is intentionally ignored. To confirm your install, load the deployed site rather than your dev server.

Install the tracking snippet#

One script tag powers pageviews, engagement, and every event rule. Replace YOUR_SITE_ID with your site's ID:

html
<script defer data-site="YOUR_SITE_ID" src="https://your-domain.com/s.js"></script>

Where to get your exact snippet

Where to put it

  1. Paste it into the HTML of every page you want to track — normally in your shared layout, template, or theme footer.
  2. Place it just before the closing </body> tag. The defer attribute means it never blocks rendering.
  3. Deploy, then load a tracked page in a normal browser tab.

Site ID rules

A site ID is lowercase letters, numbers, and hyphens, between 3 and 40 characters. The data-site value in your snippet must match the site ID exactly, or nothing will be recorded.

Note

The attribute is data-site, not data-site-id. Copying the snippet from the app avoids typos.

What's tracked automatically#

Once the snippet is installed, all of this works with no extra configuration.

WhatHow it works
Pageviews Recorded on load. Only the path is stored (/pricing), never the full URL with query string.
Single-page app routes History changes (pushState, replaceState, back/forward, hash changes) each count as a new pageview.
Sessions A session ends after 30 minutes of inactivity. Identifiers live in localStorage scoped to your site — no cookies.
Engaged visits A pageview is marked engaged once the visitor has been on it for 10 seconds.
Outbound clicks Clicks on links to another domain are recorded as an outbound event with the URL and link text.
File downloads Clicks on links ending in pdf, zip, dmg, exe, csv, xlsx, doc, docx, mp3, mp4, mov, or wav are recorded as a download event.
UTM campaigns utm_source, utm_medium, and utm_campaign are read from the page URL.
Referrers Captured and grouped into Direct, Search, Social, Referral, and Other. Links from your own site are not counted as referrers.
Country Looked up from the IP address at the moment of collection. The IP itself is never stored.
Browser, OS, device Derived from the user agent string, which is not stored.
Bots Known crawlers and bots are discarded before anything is saved.
Not tracked

Visits from localhost or 127.0.0.1, and visitors whose browser sends Do Not Track or Global Privacy Control signals. Password field values are never captured, even by an event rule that captures input values.

Dashboard#

The dashboard lives at /app. Everything on the page — cards, chart, breakdowns, and goals — always reflects the site, date range, and filters you have selected.

Controls & date range#

Three controls sit above the stats:

ControlWhat it does
Property Switches sites. Sites you own are grouped under Your sites; sites a teammate shared appear under Shared with you.
View Opens the Views menu: apply a saved view, save the current one, or export CSV. Shows Custom when your current setup does not match a saved view. See Saved views.
Range Date range presets: Today, 7d, 30d, 90d, Custom.

7d, 30d, and 90d include today. To use an exact window, click Custom, pick a start and end date, then click Apply — data loads only after you apply.

Heads up

Changing the date range clears any active filters. Set your range first, then drill down.

Metrics explained#

CardDefinition
VisitorsDistinct sessions in the selected range.
PageviewsTotal pageviews, including repeat views of the same page.
Bounce rateShare of sessions with exactly one pageview.
Engaged visitsPageviews where the visitor stayed at least 10 seconds.

The small text under each number changes depending on whether a filter is active:

The chart#

The chart plots one point per day for whatever metrics you have selected.

  1. Click any summary card — Visitors, Pageviews, Bounce rate, or Engaged visits — to add that line to the chart.
  2. Click more cards to overlay several metrics at once. Active cards are outlined in the line's color.
  3. Click an active card again to remove it. At least one metric always stays on the chart.
  4. Click a goal card above the chart to overlay that goal's conversions as a dashed gold line. One goal at a time.

Bounce rate is drawn on its own percentage axis on the right, so you can compare it against visitor counts without the scales fighting each other.

Live visitors#

The Live strip at the top of the dashboard counts distinct sessions with a pageview in the last 10 minutes, and refreshes every 10 seconds. Next to it, the feed shows the five most recent pageviews from the last 30 minutes with their country, referrer, and UTM tags.

Breakdowns#

Each breakdown card lists the top ten values for the current range and filters.

CardClicking a row
Top pagesOpens the page details panel.
ReferrersFilters the dashboard to that referrer. Traffic with no referrer appears as (direct).
SourceFilters by channel: Direct, Search, Social, Referral, or Other.
CountriesFilters by country.
DevicesFilters by device type.
Browsers, OSRead-only breakdowns.
UTM Sources, UTM Mediums, UTM CampaignsRead-only breakdowns of your campaign tags, at the bottom of the page.
Tip

To measure a campaign, add utm_source, utm_medium, and utm_campaign to the links you share. No setup is needed — the tracker reads them from the URL on arrival.

Explore your data#

Filters#

Filters narrow the entire dashboard — cards, chart, every breakdown, and all goal conversion rates — to one segment of traffic.

  1. Click a row in Referrers, Source, Countries, or Devices.
  2. A purple chip appears above the stats, for example Country: US. Everything reloads for that segment.
  3. Add chips from other cards to narrow further — you can combine referrer, source, country, and device.
  4. Remove a filter with the on its chip, or by clicking the same row again.

While a filter is active, goal cards show how that segment converts compared with your site overall, which is the fastest way to find out which channel actually produces signups.

Page details#

Click any row in Top pages to slide open a panel for that single page.

Close the panel with , the Escape key, or a click outside it.

Saved views#

A saved view stores a date range, all active filters, and the metrics you had on the chart, so you can return to a specific question in one click.

Save a view

  1. Set up the dashboard: pick a range, apply filters, choose chart metrics.
  2. Open the Views menu and choose Save current view…
  3. Name it, optionally tick Set as default for this site, and save.

Use and manage views

CSV exports#

  1. Set the site, date range, and any filters you want included.
  2. Open the Views menu.
  3. Choose Export pageviews CSV or Export events CSV.
ExportColumns
Pageviews timestamp, path, referrer, utm_source, utm_medium, utm_campaign, country, browser, os, device, engaged
Events timestamp, key, path, attributes

Conversions#

Conversions use two pieces that work together. An event rule decides what on your site gets recorded; a goal turns those records into a conversion rate. Creating a rule creates its goal for you, so most people never think about the difference.

Goals#

A goal counts how many sessions reached something you care about. There are two types:

TypeMatchesExample
Pageview Visitors who loaded a path. End the value with /* to match everything below it. /thanks or /docs/*
Event Visitors who triggered an event with a given key. signup_click

Add a goal manually

  1. In the dashboard, scroll to Goals and click + Add Goal.
  2. Enter a Goal name, for example Signup complete.
  3. Choose Pageview or Event as the type.
  4. Enter the Match value — a path for pageview goals, or an event key for event goals.
  5. Save. The goal starts counting from data already collected.

Read a goal

The goals table shows conversions, unique converters, and conversion rate. Click the arrow on a row to expand it and see the pages that led to conversions, referrers at conversion, and breakdowns by country, source, and device.

Feature goals above the chart

  1. Click Customize in the goals strip above the chart.
  2. Tick up to three goals to show as summary cards.
  3. Click a card to plot that goal's conversions on the chart.

Visual picker#

The fastest way to track a click. You pick the element on your own site and StatsNGraphs works out the selector.

  1. Make sure the tracking snippet is live on the page you want to work on.
  2. In the dashboard, go to Event Rules and click Visual picker.
  3. Enter the Page URL that contains the element, then click Open picker. Your site opens in a new tab with a StatsNGraphs banner at the top.
  4. Hover links, buttons, and form fields to highlight them, then click the one you want. Password fields are excluded.
  5. Switch back to the dashboard tab. The rule form is already filled in — give the rule a name, adjust the capture options, and save.

A matching goal is created automatically, so the new conversion appears in Goals without any extra work.

Heads up

The picker opens a new tab, so allow pop-ups for the dashboard. If the banner does not appear on your site, the snippet is not installed on that page yet.

Event rules#

A rule says "when this element does this, record this event." Rules live on the server, so you can add and change them without touching your site's code again. Use + Add Rule when you already know the selector.

FieldWhat to enter
Rule nameA label for you, for example CTA button click.
TriggerClick, Form submit, or Becomes visible (fires when the element scrolls into view).
CSS selectorThe element to watch, for example #signup-btn or [data-track="signup"].
Event keyThe name stored with each event, for example cta_click. This is what an event goal matches on.
Capture element textOn by default. Stores the element's visible text, which is useful for telling several buttons apart.
Capture input valueStores what the visitor typed. Use it for search boxes — see Search terms.
Capture link or form URLStores the link's href or the form's action.

Test a rule before you trust it

  1. Click Test on the rule's row.
  2. Click Open test. Your site opens with every matched element outlined in green and a banner showing how many matched.
  3. Interact with the element. The dashboard confirms Test event received!
  4. Set the range to Today and check the matching goal.
Note

New and changed rules reach visitors within about five minutes, because each browser caches the rule list for five minutes.

Custom events in code#

For things a selector cannot catch — a successful API response, a completed multi-step form, a payment confirmation — call the tracker directly. It is available on window.sng as soon as the snippet has loaded.

javascript
// Simple event
window.sng.track('signup');

// With attributes
window.sng.track('signup', { plan: 'pro', source: 'pricing_page' });

// Safe to call before the script has loaded
window.sng?.track('checkout_complete', { value: 49 });
Note

window.analytics.track(...) works as an alias, but only when no other script (such as Segment) has claimed that name. Prefer window.sng.track(...).

Search terms#

See what visitors type into your site search.

  1. Create an event rule for your search input — the visual picker handles this well.
  2. Set the trigger to Form submit so the term is captured once, on submit.
  3. Turn on Capture input value and save.
  4. Expand the rule's goal in Goals to see Top search terms and Recent searches. Use View all for the full list.
Privacy

Capture input value stores exactly what visitors typed. Only enable it on fields that will not contain personal data, and never on login or checkout forms. Password fields are always excluded.

Sites & team#

Everything in this section lives in Account, which is organized into Profile, API Keys, Sites, Organization, Team, and Billing tabs.

Signing in#

  1. Go to /login and enter your email.
  2. Click Send me a sign-in link.
  3. Open the email and click through — the link is valid for 15 minutes and can be used once.

Managing sites#

Add a site

  1. Open Account → Sites.
  2. Enter a Site name and a Site ID (lowercase letters, numbers, and hyphens).
  3. Click Add site, then Get snippet and install it.

You can also add sites from the + Add website button in the All sites hub.

Other actions

All sites hub#

Once you have two or more sites, /app opens the hub instead of a single dashboard. Each tile shows visitors in the last 24 hours, the trend against the day before, and a seven-day sparkline. Click a tile to open that site's dashboard, or use All sites in the top bar to come back.

Team & roles#

Your sites belong to a workspace, and everyone in the workspace can see them.

  1. Open Account → Team.
  2. Enter a teammate's email under Invite by email.
  3. Click Send invite. They receive a sign-in link that joins them to your workspace.
RoleCan do
OwnerEverything, including removing members.
AdminInvite teammates, rename the workspace, manage billing.
MemberView analytics and manage goals and rules for workspace sites.

Rename the workspace under Organization. Owners can remove a member from the Team tab.

Weekly email digest#

Every Friday, StatsNGraphs emails you a highlight of the week for the sites you own: a one-line takeaway, visitors, pageviews, bounce rate, and engaged visits with week-over-week changes, plus top pages, top referrers, and goal conversions. Each section links into the matching part of the dashboard so you can open a page, filter a referrer, or jump to goals.

To turn it off, open Account → Profile and untick Email me every Friday with week-over-week traffic changes.

Plan & billing#

Workspaces start on the Free plan, and every feature in these docs works on it. Workspace admins can open Account → Billing and click Upgrade to Pro to start a checkout; the plan badge updates once payment is confirmed. If you are not an admin, the tab points you to whoever manages billing for the workspace.

TBD

Pricing is still being worked out — the direction is pay what you can, and there are no usage caps enforced today. This section will be updated once the details are settled.

Share & integrate#

Give a client or teammate read-only access to one site's dashboard without creating an account for them.

  1. Open Account → Sites and find the site.
  2. Click Enable sharing.
  3. Copy the Shared link and send it.

AI assistants (MCP)#

StatsNGraphs exposes a read-only MCP endpoint, so an assistant can answer questions like "which referrer converted best last week?" against your real data.

MCP endpoint
https://your-domain.com/mcp

Claude.ai

  1. In Claude, add a custom connector using the MCP URL above.
  2. Leave the OAuth Client ID and Secret blank — Claude registers itself automatically.
  3. When prompted, sign in to StatsNGraphs and click Allow on the consent screen.

Cursor, Claude Code, and other MCP clients

  1. Create an API key in Account → API Keys and copy it.
  2. Add the server to your client's MCP config, using the key as a bearer token.
  3. Restart the client and ask it about your traffic.
mcp.json
{
  "mcpServers": {
    "statsngraphs": {
      "url": "https://your-domain.com/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_API_KEY"
      }
    }
  }
}

Available tools

ToolReturns
list_sitesThe sites this key can read.
get_summaryVisitors, pageviews, bounce rate, and engaged visits for a range.
get_timeseriesDaily visitors, pageviews, engaged visits, and bounce sessions.
get_top_pagesTop pages by pageviews.
get_top_referrersTop referrers, including direct traffic.
get_breakdownTraffic by source, country, browser, OS, device, or UTM dimension.
get_goalsGoal conversions and conversion rates.
get_realtimeActive visitors in the last 10 minutes and recent pageviews.
Note

Every MCP tool is read-only — an assistant can never change goals, rules, or settings. Revoke access anytime under Connected apps or by deleting the API key.

API keys#

  1. Open Account → API Keys.
  2. Enter a Key name that says where it will be used, for example Cursor on laptop.
  3. Click Create key and copy the key immediately — it is shown only once.

Keys start with sng_ and are sent as Authorization: Bearer sng_…. Click Revoke on any key to cut off connected clients right away. OAuth connections such as Claude.ai appear separately under Connected apps.

Reference#

Privacy & data#

TopicHow StatsNGraphs behaves
CookiesNone are set on your visitors. Session and visitor identifiers are kept in localStorage, scoped to your site.
IP addressesUsed only in memory to look up a country, then discarded. Never stored.
User agentsParsed into browser, OS, and device. The raw string is not stored.
URLsOnly the path is stored. Query strings are not, apart from the three UTM parameters.
Do Not Track / GPCRespected — nothing is collected from those visitors.
PasswordsNever captured, even when a rule captures input values.
Free-text captureOnly collected when you explicitly enable Capture input value on a rule.

See the full Privacy Policy for the formal details.

Limits & retention#

LimitValue
Tracking requests300 per minute per visitor IP
Event payload size10 KB per request
MCP requests120 per minute per key or token
Sign-in link requests5 per minute
Featured goal cards3 per site
Breakdown rowsTop 10 per card
Rule propagationUp to 5 minutes
Session timeout30 minutes of inactivity
Sign-in link validity15 minutes
Login session30 days
Data retentionKept indefinitely — nothing is deleted on a schedule

These are technical safeguards, not plan quotas. There are no per-plan caps on sites, pageviews, events, or team members today — see Plan & billing.

Troubleshooting#

No data at all

An event rule never fires

Goal shows zero conversions

Referrers look wrong

Links from your own site are deliberately not counted as referrers, so internal navigation does not pollute the report. Traffic with no referrer — typed URLs, most apps, and many email clients — appears as (direct).

Still stuck

Click Send Feedback in the dashboard top bar, or email hello@statsngraphs.lol.

Something missing or out of date? Tell us and we'll fix the docs. Open the dashboard →