Collapsible

An interactive component that expands and collapses to show or hide content.

Default

A basic collapsible with a trigger button and expandable content area.

@peduarte starred 3 repositories

@radix-ui/primitives

With Animation

Content expands and collapses with a smooth height transition.

@peduarte starred 3 repositories

@radix-ui/primitives
@radix-ui/colors
@stitches/react

Nested

A collapsible inside another collapsible for hierarchical content like file trees.

Project Files

Controlled

Collapsibles with text-based triggers that toggle between "Show more" and "Show less".

Collapsible components are useful for toggling the visibility of content. They can be used to create expandable sections, FAQs, and more.

This pattern is commonly used in settings panels, sidebars, and content-heavy pages where you want to reduce visual clutter while keeping information accessible.

You can also use collapsible components to progressively disclose information to users as they need it.