The GOV.UK Design System provides an accordion component allowing users to show and hide related content sections on a page. This component is useful when users need to see an overview of multiple sections, choose which sections are relevant to them, and compare information that might otherwise be spread across different pages.
The accordion component uses JavaScript to provide an interactive experience. Sections start hidden, and users can expand and collapse them as needed. When JavaScript is not available, all content is displayed with the section labels as headings.