Skip to content
Browse docs and components

Badge

badge

A small label for status, counts and metadata, in five quiet variants and two sizes. The colour lives in the tint so the text stays readable at eleven pixels, and an icon or a dot inside the badge carries the state at a glance.

Responsive

Install

$npxshadcnadd@forme/badge

Adds the component, its registry dependencies, and the token stylesheet you import once.

API reference

Read from the source, so it is the API of the file you install. A prop marked * is required.

Badge

PropTypeDefaultDescription
variant'success' | 'warning' | 'destructive' | 'neutral' | 'brand'"neutral"
size'md' | 'sm'"md"

Also takes every prop of <span> attributes.