Skip to content
animorio
IT
All components

Live visitors chart

Charts, HoverGSAP, CSS onlyMediumCompressed weight: Demo 8.6 KBGSAP 28 KBFreeDownload the zip

The live widget of a website analytics dashboard, dark on black: the people on the site right now with rolling digits, the pageviews per minute sliding left while the new minute rises on a spring, and the top pages trading places when one overtakes another. A thread of light runs along the edge and follows the pointer.

The code

A folder that runs on its own: index.html, style.css, script.js and the libraries from a CDN.

<!doctype html>
<!--
  "Live visitors chart" from Animorio · https://animorio.com
  License: free on your own sites and your clients’ sites, paid work included.
  Not for resale, redistribution, templates or code collections · https://animorio.com/en/license/
-->
<html lang="en">
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <title>The live visitors chart with the pages that reorder</title>
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/mona-sans@5.3.0/wdth.css">
  <link rel="stylesheet" href="style.css">
</head>
<body>
  <main class="stage">
    <!-- the live visitors widget of a web analytics dashboard: the people on the site right now (digits that roll),
         a stream of pageviews per minute that slides left as each new minute rises on a spring, and the top pages
         that swap places when one overtakes another. A soft light follows the pointer along the card's edge -->
    <section class="lv" data-lv aria-label="Live visitors">
      <span class="lv__grain" aria-hidden="true"></span>
      <span class="lv__rim" aria-hidden="true"></span>

      <header class="lv__head">
        <span class="lv__title">
          <svg class="lv__signal" viewBox="0 0 20 16" aria-hidden="true">
            <path data-arc d="M7.2 10.6a3.6 3.6 0 0 1 5.6 0"/>
            <path data-arc d="M4.7 8.1a7.2 7.2 0 0 1 10.6 0"/>
            <path data-arc d="M2.2 5.6a10.8 10.8 0 0 1 15.6 0"/>
          </svg>
          Live visitors
        </span>
        <span class="lv__site" data-site>northfold.co</span>
      </header>

      <div class="lv__now">
        <p class="lv__total" data-total aria-hidden="true"></p>
        <span class="lv__delta" data-delta-chip>
          <svg viewBox="0 0 12 12" aria-hidden="true"><path d="M6 9.5V2.8M2.9 5.6L6 2.5l3.1 3.1"/></svg>
          <span data-delta aria-hidden="true"></span><span class="lv__pct">%</span>
        </span>
      </div>
      <p class="lv__sub">on the site right now</p>

      <div class="lv__label">
        <span>Pageviews per minute</span>
        <span class="lv__read" data-read><span class="lv__when" data-when>Now</span><span class="lv__sep">·</span><span data-per aria-hidden="true"></span><span class="lv__unit">views</span></span>
      </div>
      <div class="lv__chart" data-chart>
        <span class="lv__avg" data-avg aria-hidden="true"></span>
        <div class="lv__track" data-track></div>
        <span class="lv__cursor" data-cursor aria-hidden="true"></span>
      </div>

      <div class="lv__label lv__label--pages">
        <span>Top pages</span>
        <span>Active</span>
      </div>
      <ol class="lv__pages" data-pages></ol>

      <p class="sr" aria-live="polite" data-live></p>
    </section>
  </main>

  <script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/gsap.min.js"></script>
  <script src="script.js"></script>
</body>
</html>

Playground

Change values, colours and text with the controls and watch the animation respond live. Or write in the code yourself. Then download the folder with your changes.

27 values to change

Or ask your AI assistant for it

With the Animorio connector, Claude Code, ChatGPT, Cursor or VS Code take it from here, guide included, and fit it into your project. Paste this request:

Take “Live visitors chart” from Animorio and fit it into my site
Platform licenseFree on your sites and your clients’ sites. Want it inside a website builder, a template platform or a client dashboard? There’s a license for agencies and platforms.

What it does

On a black page a dark card with round corners and a very fine grain rises slowly out of a light blur: at the top ‘Live visitors’ with a small signal icon made of three violet arcs, on the right the site being watched, ‘northfold.co’. Below, the big number of people on the site right now rolls from 0000 up to 1,624, one digit after another starting from the right, each passing the mark by a breath before it settles; next to it a green pill says how much it went up against an hour ago, ‘8.0%’, with a drawn arrow. Then the pageviews per minute of the last half hour grow from left to right in a row of thin blue bars, with a dashed line at the average, and the last one, the current minute, is violet and lit. At the bottom the four top pages come in one after another, each with its number of active people and a thin line saying how much it weighs. Every two and a half seconds a new minute arrives: the three arcs light up one after another, the whole row slides one place to the left and the new bar rises on a spring taking the violet, the total and the pages roll to their new numbers, and when a page overtakes the one above the two rows trade places sliding past each other, the one that climbs with a violet light and a small arrow by its number. Moving over the row with the pointer, or a finger, a thin line marks the minute and the label above reads it, ‘14:21 · 38 views’. A thread of violet light runs along the card's edge, on its own or behind the pointer.

How it works

Digits on a strip

Each digit is a window one line high holding a strip from 0 to 9; GSAP moves it by yPercent -10 per unit, with a delay starting from the right and a back.out that passes the mark by a breath. Digits that do not change stay still, so only what changes rolls. A mask fades the window's top and bottom edges.

A row that slides one place

The bars sit in a row one column per minute. The new minute is born outside on the right, zero high; the row slides one column in 0.8 s while the new bar grows on a spring. When the slide ends the oldest bar is removed and the row goes back to x 0 without a jump.

Pages overtaking

The four rows are absolute, each at y = rank times row height. On every minute the numbers are sorted again: rows that change rank slide to their new y with a back.out, the one going up passes over the other (z-index) and lights up for a moment, with a small SVG arrow by its number.

Reading a minute

The pointer over the row finds the column from x minus the row's current offset, divided by one column's width, even while it slides. The label above gives the time and the number (which rolls), a thin line settles on the bar. With a finger the minute stays read for a moment after lifting it.

The thread of light on the edge

A layer as big as the card has a radial gradient placed at --mx and --my and a mask that shows only a one pixel ring (content-box against border-box). A timeline walks it slowly round the card; with a pointer it follows through quickTo and, once the pointer rests, goes back to walking.

Values to change

NameFileDefaultWhat it changes
TICKscript.js2.4Seconds between two live updates (each one is a minute of the site).
BARSscript.js26How many minutes the row shows.
ROLLscript.js0.7How long a digit takes to roll, in seconds.
STAGGERscript.js0.05The delay between two digits, starting from the right.
OVERSHOOTscript.js1.6How far a page passes its new place, and a new minute its height, before settling.
GLOWscript.js0.9How bright the thread of light on the edge is.
SITEscript.jsnorthfold.coThe site being watched, top right.

Try them in the Playground

When to use it

For the dashboard of a website analytics tool, an online shop's panel during a sale, the back office of a blog or a landing page on launch day, the control room of an event's ticket sale: anywhere you need to see who is there right now and where they are looking.

On phones

The card takes the screen's width minus a margin, and the number, the row of minutes and the page rows are measured on the height too, so everything fits in the box. With a finger: a tap on the row reads the minute, dragging sideways moves it, up or down the page scrolls as usual.

With reduced motion

The card fades in; the digits change with a short fade instead of rolling, the row does not slide (the bars take their new places and the new one fades in), the pages change places by fading out and in and the thread of light stays still at the top.

Pitfalls

  • With the row sliding, the minute under the pointer has to be found by removing the row's current offset (gsap.getProperty), otherwise halfway through the slide it reads the minute next to it.
  • A text gradient set on the whole number does not reach inside the digit windows: the gradient goes on each digit of the strip, one line high.
  • On resize the bar heights are in pixels: the running springs are stopped, everything is measured again and the row goes back to x 0, or a bar halfway up ends at its old height.

Libraries

GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.

Compressed with gzip, the three demo files weigh 8.6 KB; the libraries: GSAP 28 KB.

Testing

Tested on 1 November 2026

  • Desktop: Done
  • Phone: Done
  • Reduced motion: Done
  • Safari on iPhone: To do

License

Use it in your own projects and in your clients’ projects. Do not resell it or redistribute it as is. GSAP stays under its own Standard license. Full license.

All components