Accordion

Android · iOS · Web
The accordion component allows users to expand and collapse related sections of content for streamlined information presentation.

Overview

Accordions allows users to expand and collapse content, providing a space-efficient way to progressively disclose information. They help organise and present complex information in a structured and user-friendly manner.

Live demo

  1. List item 2
  2. List item
  3. List item
  1. List item 2
  2. List item
  3. List item
  1. List item 2
  2. List item
  3. List item
Modifiers

Usage

Do

  • Use when needing to condense large amounts of information into a compact space.

  • Clearly label each Accordion item header to indicate the content it contains.

  • Use icons or arrows to indicate expand/collapse actions to make Accordions more discoverable.

  • Ensure the Accordion works well on various screen sizes and devices.

Don't

  • Avoid placing excessive content within Accordion items, as it may defeat the purpose of decluttering.

  • Important information should remain visible even when Accordions are collapsed.

  • Ensure the Accordion is accessible to users with disabilities, providing proper focus and ARIA attributes.

  • If there's only a small amount of content, consider displaying it without an Accordion for a simpler user experience.

  • Don’t nest Accordions inside other Accordions.

Sizes

There are 4 size variants for the Accordion component; small, medium, large, x-large.

SizeExample
Medium (default)

Expanded content

Small

Expanded content

Large

Expanded content

X-Large

Expanded content

States and interactions

SizeExample
Enabled

Content

Disabled

Content

Hover

Content

Focused

Content

Accessibility

  • Enhance accessibility by including appropriate ARIA roles and attributes, such as aria-expanded and aria-labelledby.

  • Regularly test the Accordion with screen readers to ensure compatibility and a smooth experience for users with visual impairments. Make sure all Accordion interactions are operable using a keyboard alone.

iOS guidance

Along with the guidance above, there is some iOS specific guidance for this component.

  • Leverage iOS-specific animations for smooth and visually appealing transitions when expanding or collapsing Accordion sections.

  • Test and optimise the Accordion for various iOS devices, including iPhones and iPads.

  • Leverage iOS accessibility features and test with VoiceOver to ensure a seamless experience for users with disabilities.