Button

Form Controls
Local guide ↗ import { Button } from "bits-ui"

Action variants

One behavioral primitive, styled for primary, secondary, destructive and disabled states

Choose an action

Links as buttons

Adding href changes the underlying element from button to anchor

Navigation action

Passing href makes the root render an anchor while retaining the button skin.

Explore Command

External destination

Standard anchor attributes pass through to the rendered element.

Local Button guide

Button.Root chooses its element from its props: without href it is a button, while supplying href renders an anchor for real navigation semantics. Use the link form for destinations, not merely to make an action look like a link.

The disabled prop prevents interaction and defaults to false. Every root exposes data-button-root, giving every visual variant a stable styling hook without duplicating behavior.