GalleryPremium

Reverse Marquee

A line of words gliding to the right, against the usual ticker direction, full at any width, stopping under the mouse or with its Pause button.

CSSJSReverse

Updated

This effect is part of Effect.Labs — 846 vanilla effects, some free, some premium. Gallery has 44 effects, including 6 free. Explore the category →

3 usage examples

Plates of a conveyor-belt sushi restaurant — the menu moves to the right, like the counter — Reverse Marquee example 1

① Plates of a conveyor-belt sushi restaurant — the menu moves to the right, like the counter

WhenAt the foot of the Okavelle home page, under the heading “What is passing in front of you this lunchtime” and the price key, a dark belt carries the plates: salmon, red tuna, prawn, sweet omelette, each with the coloured rim that gives its price.
WhyThe direction is not a style choice: in the dining room the belt turns to the right, so the menu does the same. Each card is short (a name, a price): coming in by its end does not get in the way of reading.
Settingsdata-direction="right", data-speed="55", --rvmq-space: 12px, --rvmq-size: 12px, --rvmq-bg: transparent, --rvmq-height: auto, --rvmq-padding: 0, --rvmq-button-size: 26px; each <li> is a white card: a plate drawn in CSS, a name, a price.
“Slide to confirm the round” slider — delivery drivers' app of a bakery — Reverse Marquee example 2

② “Slide to confirm the round” slider — delivery drivers' app of a bakery

WhenAt 6:42 am, the twelve drop-offs of Fournil Brisenne are ticked. In the “Round finished?” panel, the green slider sends “Slide to confirm” and three chevrons from the round knob towards the right edge.
WhyThe movement shows the expected gesture and its direction, without one more line of help text. The effect only supplies this animated hint: the round knob you drag belongs to the app.
Settingsdata-speed="42", --rvmq-size: 12px, --rvmq-space: 16px, --rvmq-color: #bbf7d0, --rvmq-button-size: 22px; the .rvmq-viewport window gets the rounded green background and 48 px of left padding for the round knob; the chevrons are an <li aria-hidden="true">.
Toys accepted by a toy library's collection drive — the band glides towards the “Drop off a toy” button — Reverse Marquee example 3

③ Toys accepted by a toy library's collection drive — the band glides towards the “Drop off a toy” button

WhenOn the toy-drive page of La Ludarelle, under the headline, one block joins the “We take” list (complete board games, jigsaws, bricks, dolls, toy cars) and the coral button stuck to its right edge.
WhyThe words travel towards the button: an eye following the band ends up on it. The other way round, they would move away from it. A chevron between two words recalls the direction when the band is paused.
Settingsdata-speed="48", --rvmq-size: 13px, --rvmq-space: 14px, --rvmq-color: #1f2a44, --rvmq-button-size: 24px; flex-direction: row-reverse on .rvmq-band to move the Pause button to the left, a chevron as ::after of each <li>, a mask-image fade on the left edge of the window.

How it works

The direction comes from one attribute: data-direction="right" on the root. The CSS answers with animation-direction: reverse: the rvmq-scroll animation is played backwards, the track starts one list length back and returns to zero. Remove the attribute, or write left, and the line heads left again.

Going the other way changes how it reads, and this was measured: what comes in at the left edge is the end. The last entry of the list passes first (in the demo: “Creative Motion”, then “Opposite Flow”, then “Reverse Direction”) and each group of words shows up by its last letters. So favour short items — a word, a price, a name — and when order matters, write the list back to front.

The list is written once. The script measures its width, copies it until the window is covered, plus once more, then sets the duration to hold 70 px per second (data-speed): 14 seconds for the 976 px of the demo list. It recounts when the area gets wider or when a script changes the list.

Worth knowing before you buy: the engine is the one in Basic Marquee, which takes the same attribute. Reverse Marquee is that ticker shipped facing the other way, in magenta, inside a 180 px frame.

Accessibility

  • Stopping the line: a round 32 px button with aria-pressed, by mouse, finger or keyboard (Tab, then Space or Enter); resting the mouse on the line holds it too.
  • Heard order, seen order: a screen reader reads the list as you wrote it, once (the copies carry aria-hidden="true"), while on screen it passes in reverse order. If you flip the list for the eye, read it aloud again.
  • Links: Tab only visits the links of the original list. The link reached freezes the line at its starting point and gets a 2 px outline drawn inwards, so the window crops neither its top nor its bottom.
  • Reduced animations: when the system asks for it, the line does not start; it shows the list once, without a button, and is moved by finger, wheel, or arrow keys after Tab.
  • Contrast: magenta #d946ef on #0a0a0f, 5.7:1.

Browser compatibility

One CSS animation played backwards over an offset passed through a variable, 5 KB of script, no library. The most recent pieces: :focus-visible for outlines (Chrome 86, Firefox 85, Safari 15.4), flexbox gap (Chrome 84, Safari 14.1), ResizeObserver (Chrome 64, Firefox 69, Safari 13.1). Measured on 4 December 2026 in Chromium, Firefox and WebKit: 70 px/s to the right, two independent lines in one page, full line at 390 and 1,900 px, including inside a dir="rtl" page.

Chrome 86+✓ Full (measured)
Firefox 85+✓ Full (measured)
Safari 15.4+✓ Full (WebKit engine measured)
Edge 86+✓ Full (Chromium engine)
iOS Safari 15.4+✓ Not verified on a device
Android Chrome 86+✓ Full (emulated touch, measured)

Without JavaScript, the list stays put, written once, and is dragged by hand. In an older browser the line still scrolls: it lacks the drawn focus outline and the gap between the line and the button; without ResizeObserver, the recount waits for the window to be resized.

The code

HTML structure to paste into your page (the CSS + JS come with your purchase):

index.html — structure
<div class="fx-0188-root" data-speed="70" data-direction="right">
  <div class="rvmq-band">
    <div class="rvmq-viewport">
      <div class="rvmq-track">
        <ul class="rvmq-group" role="list">
          <li>A short word</li>
          <li><a href="/page">A link</a></li>
        </ul>
      </div>
    </div>
    <button type="button" class="rvmq-toggle" aria-pressed="false" aria-label="Pause"></button>
  </div>
</div>

One-time payment, no subscription — the code is yours forever

Customize

Options passed to the API or data-* attributes:

Option / propertyDefaultEffect
data-direction right right: to the right; left or no attribute: to the left.
data-speed 70 Pixels travelled per second; the animation duration follows from it, whatever the length of the list.
List (HTML — one <li> per item) 4 two-word groups Text, link or small block; the order of passage on screen is the reverse of the written order.
--rvmq-color / --rvmq-size #d946ef / 1.5rem Text colour and size (weight 600).
--rvmq-space 4rem White space between two items, split into margins on either side.
--rvmq-height / --rvmq-bg / --rvmq-padding 180px / #0a0a0f / 1rem 0 Frame around the line; auto, transparent and 0 to set it into your page.
--rvmq-button / --rvmq-button-size rgba(255, 255, 255, .8) / 2rem Tint and diameter of the Pause button.

FAQ

The starting direction, and nothing else in the engine. Both effects share the same script and the same animation, and each takes data-direction="left" or "right". Reverse Marquee comes set to the right, at 70 px/s instead of 85, in magenta inside a 180 px frame. If you already own Basic Marquee, one attribute is enough to get this direction.
Yes: in a dir="rtl" page the window sets its own building direction, so the band does not go empty, and the Pause button moves to the left, like the rest of the page. The right-hand direction is then the natural one: a sentence comes in by its beginning. Add dir="rtl" on the .rvmq-group list so the first item sits on the right.
That is what a line heading right does: the item written last comes in first. Write the list back to front or, for a sequence that must read in order (steps, rankings), go back to data-direction="left". Screen readers always follow the HTML order.