Skip to content

Separator

Free

A line between groups of content, horizontal or vertical: solid, dashed, dotted, double, or fade, in any status tone, with an optional label in the middle.

  • Base UI
  • React 19
  • Tailwind CSS 4

Added Nov 8, 2026 · MIT + Commons Clause

Playground

Loading the preview

Props

A horizontal line fills the width, and the gap of the parent sets the space on each side.

docs-links.tsx

Separator

<div>
PropTypeDefaultDescription
classNamestring—
variant"dashed""dotted""double""fade""solid""solid"The line pattern. Default: solid.
tone"default""destructive""info""muted""primary""success""warning""default"The color, from the shared tokens. Default: default (the border color).
childrenReactNode—Content in the middle of a horizontal line: "or", a date, an icon. The line then splits in two halves around it, and a text label is the name that screen readers hear.
From Base UISeparatorBase UI docs
orientation"horizontal""vertical""horizontal"The orientation of the separator.
render—Allows you to replace the component's HTML element with a different tag, or compose it with another component. Accepts a ReactElement or a function that returns the element to render.
style—Style applied to the element, or a function that returns a style object based on the component's state.
...props<div> attributes—Every other attribute goes to the <div>, with a ref.
  • Use it when a line makes a group easier to see.
  • Use orientation="vertical" between items of a row.
  • Use variant for solid, dashed, dotted, double, or fade, and tone for the color.
  • Pass children to put a label in the middle.
  • When space alone groups the content, use space and no line.
  • For a wavy, zigzag, or stitched line, use the Decorative Separator.

It is a Base UI Separator with role="separator" and the right aria-orientation.

A string label becomes the aria-label of the separator.

  1. AddedSeparator.
Open the release