3DPremium

Carousel 3D V2

Five large slides in a ring, turning slowly around a vertical axis, one turn every 20 seconds, pausing on hover and on focus. Pure CSS.

CSS3DCarousel

Updated

This effect is part of Effect.Labs — 846 vanilla effects, some free, some premium. 3D has 50 effects, including 8 free. Explore the category →

3 usage examples

Revolving stand of new paperbacks — a station bookshop's website — Carousel 3D V2 example 1

① Revolving stand of new paperbacks — a station bookshop's website

WhenTop of the home page: the headline and the button on the left, and on the right five paperbacks turning around a pole, like the spinner rack standing by the till.
WhyThe revolving stand is part of a station bookshop's furniture; you recognise it before reading a word. Two covers show at a time, the others are on their way: people stay a few seconds longer to see the next one come round.
SettingsSlides switched to paperback format (88 × 128 px, spine marked by an inner shadow), same five gradients, same 150 px radius, same 20 s turn; 200 px tall stage; pole and floor shadow added by the page; ring made insensitive to the mouse (pointer-events: none) since it is a shop window — keyboard focus still pauses it.
Who opens the night? — drawing the running order of an open mic in a café — Carousel 3D V2 example 2

② Who opens the night? — drawing the running order of an open mic in a café

WhenFive acts signed up, one per slide. The ring spins fast; the host clicks “Stop!”, the ring freezes and the name of whoever is facing appears below. “Draw again” sets off for the next one.
WhyA draw has to be seen: everyone follows the names going round and sees which one stops in front. The ring puts on the show, and the result is also spelled out for those who cannot see it.
SettingsTurn cut to 3 s (animation-duration); the stop is a class set by the page that applies animation-play-state: paused to the track; the page's script reads the angle in the .crv-track matrix to name the facing slide; ring in aria-hidden and insensitive to the mouse, the result being announced in an aria-live region.
Baggage belt: delivery in progress — a regional airport's app — Carousel 3D V2 example 3

③ Baggage belt: delivery in progress — a regional airport's app

WhenCard for the flight that has just landed: as long as bags are coming out, five little suitcases go round on a miniature belt above “Delivery in progress” and the progress bar.
WhyThe baggage carousel is the very picture of waiting on arrival: the miniature says “it's turning” without a sentence. It takes up 180 px of width and needs no script; when delivery is over, just remove it.
SettingsSlides shrunk to 44 × 30 px with a handle as a pseudo-element; radius brought from 150 down to 58 px by rewriting the five translateZ values; perspective at 600 px; one turn in 9 s; 180 × 92 px stage; ring in aria-hidden, the status being written below.

How it works

Three levels are enough. The .crv-stage box (280 × 180 px) carries perspective: 1000px; the .crv-track keeps its children in space with transform-style: preserve-3d; five 120 × 80 px .crv-slide elements are centred and then set on a circle: each is turned 72° further than the previous one (rotateY) and pushed 150 px away from the axis (translateZ(150px)). The ring is therefore 300 px across, and the slide passing in front is closer to the eye than the stage: measured face-on it is 141 × 94 px, 18% more than its written size.

The motion is a single animation, crvSpin, which turns the track from 0 to −360° in 20 s, at constant speed and without end: a slide comes face-on every four seconds and leaves towards the left. backface-visibility: hidden wipes out slides seen from behind, otherwise their text would show back to front through the ring. The result: you see two of them, sometimes three — the one facing you and its neighbours, squeezed to 21 px wide when they are almost side-on. The other three gradients wait their turn at the back.

The ring stops so that it can be read: animation-play-state: paused when the mouse is over the stage, when the stage has focus, or when an element placed in a slide has it. It resumes where it stopped. No script: two rings on the same page turn and stop independently (measured: hovering the second does not freeze the first). The root clips whatever sticks out of it, so that a ring wider than the screen adds no horizontal scroll.

Accessibility

  • Pause: content that moves for more than five seconds must be stoppable. Measured in all three engines: hovering pauses the animation, so does Tab (the stage carries tabindex="0", a 2 px lavender outline marks it), and in touch emulation a tap on the stage freezes it for as long as it keeps focus.
  • Reduced motion: for a visitor who has asked for less animation, the animation is removed. The ring stays still, first slide facing, its two neighbours side-on. The other three are never visible in that case: if each slide carries information, also provide it as a list.
  • Screen readers: the stage is a group named by aria-label (English text to adapt). The five slides are read in HTML order, visible or not, regardless of which one is facing. For a purely decorative ring, use aria-hidden="true" instead and remove tabindex.
  • Links inside slides: possible, but careful. A slide turned to the back is invisible and yet still reachable with Tab: focus lands on something you cannot see. Keep the ring for display and back it up with a real list of links.
  • Contrast: 12 px white text on five gradients. Computed from the CSS colours: 4.2:1 to 4.5:1 on the first, violet one; around 3.5:1 on the two pinks; 2.4:1 on the turquoise-green one and 2.1:1 at the orange end of the fourth. Switch those last two to dark text, or darken their gradients.

Browser compatibility

CSS only, 2.6 KB. Verified with Chromium 149, Firefox 151 and WebKit 26.5: same 20 s animation, same pauses on hover and focus, still ring under reduced motion, two independent copies, no horizontal scroll at 320 px. The depth is right in Chromium and Firefox. The WebKit test build, however, draws the five slides flat in a row, the back ones mirrored: that test engine flattens CSS 3D, which says nothing about the real Safari — not verified. Per MDN: transform-style: preserve-3d and perspective since Chrome 36, Firefox 16, Safari 9; unprefixed backface-visibility since Safari 15.4 (the code does not write the -webkit- form); :focus-within since Chrome 60, Firefox 52, Safari 10.1.

Chrome 60+✓ Full (measured, depth seen)
Firefox 52+✓ Full (measured, depth seen)
Safari 15.4+✓ Not verified on a real Safari
Edge 79+✓ Not verified (same engine as Chrome)
Mobile iOS 15.4+✓ Not verified
Android Chrome 60+✓ Measured in emulation: a tap pauses

Without 3D transforms the five slides pile up in the middle of the stage: only the last one shows. Before Safari 15.4, add -webkit-backface-visibility: hidden to .crv-slide, otherwise slides seen from behind appear mirrored. Without :focus-within, pausing on hover and on stage focus still works.

The code

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

index.html — structure
<div class="fx-0019-root">
  <div class="demo-3d">
    <div class="crv-stage" tabindex="0" role="group" aria-label="…">
      <div class="crv-track">
        <div class="crv-slide">…</div>
        <div class="crv-slide">…</div>
        <div class="crv-slide">…</div>
        <div class="crv-slide">…</div>
        <div class="crv-slide">…</div>
      </div>
    </div>
  </div>
</div>

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

Customize

Options passed to the API or data-* attributes:

Option / propertyDefaultEffect
Turn duration (CSS — animation: crvSpin 20s linear infinite) 20 s A slide comes face-on every four seconds. 40 s for a calm backdrop, 9 s for a small indicator. Below 5 s nobody reads any more.
Direction (CSS — @keyframes crvSpin) from 0 to −360°: facing slides leave towards the left Write rotateY(360deg) in the to step to send them off to the right.
Radius (CSS — translateZ(150px) in the five .crv-slide:nth-child() rules) 150 px, i.e. a 300 px ring At 83 px, five 120 px slides touch edge to edge; at 150 px they are spaced out and you rarely see more than two. Change the value in all five rules.
Number of slides (HTML + CSS — angle of each rotateY) 5, every 72° The angle is 360 divided by the count: 60° for six, 45° for eight. Add one :nth-child() rule per slide and widen the radius so they do not overlap.
Slide size (CSS — .crv-slide { width; height; margin }) 120 × 80 px, margins of −40 px and −60 px The two negative margins are half the height and half the width: they centre the slide on the axis. Change them along with the size.
Perspective (CSS — .crv-stage { perspective: 1000px }) 1000 px 600 px strongly enlarges the facing slide and squashes the side ones; 2000 px flattens the whole thing.
Pause (CSS — .crv-stage:hover .crv-track and the two focus rules) stops on hover, on stage focus and on focus of a child For a stop driven by a button, apply animation-play-state: paused to .crv-track yourself. Do not remove these rules without offering another way to stop the motion.

FAQ

Same build, different proportions. 3D Carousel spins six small 80 × 60 px tiles on a 100 px radius, one turn in 10 s, towards the right: a lively merry-go-round where you often see three tiles. This version takes five larger slides (120 × 80 px, 141 wide when facing), a 150 px radius and a turn twice as slow, towards the left: each slide stays readable longer and can carry a title and a line. If you already own one, you get the other by changing a few values; take the one whose starting settings are closest to your content.
With a negative delay. The animation being steady, slide number n faces you at (n − 1) × 4 seconds. Write for instance animation-delay: -8s; animation-play-state: paused on .crv-track: the ring shows up frozen, third slide facing (checked: 141 × 94 px, centred). Remove paused for it to set off from there.
Yes. Add overflow: hidden to .crv-slide and place an image in it with width: 100%; height: 100%; object-fit: cover, or give each :nth-child() a background-image instead of the gradient. Plan for files of at least 290 × 190 px: the facing slide is shown at 141 × 94 px, twice that on a Retina screen. Keep alternative text on every image.