Skip to content
TrademarkTrademark
Docs
Components

Carousel

Updated: October 11, 2026
View on GitHub

An interactive component for displaying a collection of images with smooth transitions and navigation controls. The Carousel supports both line and thumbnail indicators for navigation between images.

Five components scroll a row
Pick by the job. Carousel shows one image or slide at a time, with line or thumbnail indicators and autoplay. Swiper is a touch-first gallery on native scroll snapping. ScrollContainer moves a run of cards or tiles, with drag, wrap-around, markers and proximity scaling. Scroller scrolls overflowing chips, tabs or cards behind arrow buttons and edge fades. AutoScroll is a marquee that moves on its own. 3.0 plans to consolidate them.

Indicator

The Carousel supports two types of indicators for navigation: line (default) and thumbnail.

Controls

You can hide the controls with the controls prop.

Aspect ratio

You can customize the aspect ratio of the carousel to fit your design needs.

Auto Play

You can enable auto play with the play prop. Each field has its own default: play={{ auto: true }} moves every 3000ms with a pause button. Autoplay holds while the pointer is over the carousel, stops when keyboard focus comes into it, and does not start for a visitor who asks for reduced motion; the button then offers Play. Name the button in another language with pauseLabel and playLabel, and the carousel itself with aria-label.

Custom content

You can place custom content inside the slides as ReactNode.

API reference

Type
Default
itemsrequired
CarouselItem[][]
controls
booleantrue
priority
Eager-load the first slide. Use it when the carousel is above the fold.
booleanfalse
stretch
Drop the intrinsic aspect ratio and let slides fill their box.
booleanfalse
indicator
linethumbnailfalse
line
translateY
SpacingTokennumber
—
aspectRatio
stringoriginal
sizes
stringnumber
—
unoptimized
booleanfalse
revealedByDefault
booleanfalse
thumbnail
Sizing of the thumbnail strip when indicator is "thumbnail".
ThumbnailItem{ scaling: 1, height: "80", sizes: "120px" }
play
Autoplay: `auto`, `interval` (3000), `controls` (the pause button, on unless false), `progress`, and the button's `pauseLabel` and `playLabel`.
{ auto?: boolean; interval?: number; controls?: boolean; progress?: boolean; pauseLabel?: string; playLabel?: string; }{ auto: false, interval: 3000, controls: true }
…and every FlexProps propinherited—
auto
booleanfalse
Edit this page on GitHub