Skip to content
shadcn.io

shadcn.io is not affiliated with official shadcn/ui

Progress examples · Basic

Half Progress for React

A progress bar at 50 percent, filled to the halfway point.

Framework
UI library

A progress bar at the halfway mark: an upload half sent, a form half filled in. The same Progress as the other basic examples, with value set to 50.

Preview

Preview width

Installation

Sign in to get your install command
Free with an account. It carries your token, so the CLI installs everything in one go.

FAQ

What does the bar show?

value is 50 on the default range of 0 to 100, so the fill covers half of the track. w-full max-w-md sets its width.

What is the accessible name?

aria-label on Progress, Upload progress. The demo has no visible label, so without it a screen reader would announce a bar with no name.

How do I update the 50?

Change value as the work advances. This demo passes a fixed 50.

Which colors does it use?

The fill is bg-primary and the track bg-muted, from the theme's progress styles. This demo adds no color class.

What if my maximum isn't 100?

Pass value in the same units as the maximum. Set max on Progress: 5 steps of 5 is max 5 and value 5.

How wide is the bar?

w-full max-w-md: as wide as its container, up to 28rem. This demo sets no height. Each theme style sets its own, from h-0.5 to h-3.