Skip to content
animorio
IT
Back to the library

Speeding marquee

Scroll, Text, HoverGSAPMediumCompressed weight: Demo 2.7 KBGSAP + ScrollTrigger 45 KBFreeDownload the zip

Scroll inside the preview

An endless ribbon of words: scrolling speeds it up and tilts it in the direction of travel, and you can grab it and throw it.

Rebuilt from scratch studying demo.clapat-templates.com by Clapat: the idea is theirs; code, copy and images are ours. Read how it’s made

The code

A folder that runs on its own: index.html, style.css, script.js and the libraries from a CDN. The React and Vue tabs hold the same demo as a ready component, which switches its animations off when it leaves the page.

<!doctype html>
<!--
  "Speeding marquee" 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="it">
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <title>Nastro che accelera con lo scorrimento</title>
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/mona-sans@5.3.0/standard.css">
  <link rel="stylesheet" href="style.css">
</head>
<body>
  <main>
    <section class="spazio"><p>Scorri, o trascina il nastro.</p></section>

    <!-- data-verso: 1 va a sinistra, -1 a destra. Il primo pezzo viene copiato quanto serve -->
    <section class="nastri" aria-label="Servizi">
      <div class="nastro" data-verso="1">
        <div class="binario">
          <p class="pezzo">
            <span>Siti animati</span><i aria-hidden="true"></i>
            <span>Identità</span><i aria-hidden="true"></i>
            <span>Motion</span><i aria-hidden="true"></i>
            <span>Illustrazione</span><i aria-hidden="true"></i>
          </p>
        </div>
      </div>
      <div class="nastro nastro--vuoto" data-verso="-1" aria-hidden="true">
        <div class="binario">
          <p class="pezzo">
            <span>Fotografia</span><i></i>
            <span>Testi</span><i></i>
            <span>Negozi</span><i></i>
            <span>Video</span><i></i>
          </p>
        </div>
      </div>
    </section>

    <section class="spazio"></section>
  </main>

  <script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/gsap.min.js"></script>
  <script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/ScrollTrigger.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.

19 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 “Speeding marquee” 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

Two ribbons of words run on their own in opposite directions, one solid and one outlined. When you scroll the page they pick up speed and tilt, then slowly return to their cruising pace. With a mouse or a finger you can grab them, drag them and throw them: the push fades by itself.

How it works

One piece and its copies

The first .pezzo is copied until the track is at least twice the screen width plus one piece: there is always text on the right.

A position that wraps

The x position grows forever and gsap.utils.wrap brings it back between minus one piece width and zero. The jump back lands on an identical copy, so it cannot be seen.

The scroll push

A ScrollTrigger with no animation reads the page velocity (getVelocity). Part of it becomes extra speed, which the brake brings back to zero every frame.

The tilt

skewX follows the velocity with a soft delay (it closes 12% of the gap each frame): the ribbon leans as if it had weight.

Grab and throw

With setPointerCapture the drag continues outside the ribbon; on release the speed of the last move becomes a throw that fades out.

Values to change

NameFileDefaultWhat it changes
CROCIERAscript.js60Resting speed, in pixels per second.
SPINTAscript.js0.22How much scrolling speeds up the ribbon.
PENDENZA / MAX_PENDENZAscript.js0.012 / 10Tilt per unit of velocity and its limit in degrees. Zero removes the tilt.
data-versoindex.html1 / -1Each ribbon's direction: 1 to the left, -1 to the right.

Try them in the Playground

When to use it

As an interlude between two sections, for services, clients or keywords. Not for text meant to be read calmly.

On phones

It speeds up with finger scrolling and can be thrown with a horizontal swipe; touch-action: pan-y keeps vertical page scrolling free.

With reduced motion

The ribbons stand still, with readable words.

Pitfalls

  • Put aria-hidden on the copies, or a screen reader reads the same words five times.
  • If the font loads later, the piece width changes: recompute wrap after document.fonts.ready or on resize.
  • Never animate left or margin: transform only, or the browser recomputes layout every frame.

Libraries

GSAP 3.15.0, ScrollTrigger 3.15.0, Mona Sans (font variabile) 5.3.0.

Compressed with gzip, the three demo files weigh 2.7 KB; the libraries: GSAP + ScrollTrigger 45 KB.

Testing

Tested on 26 September 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 animations