Toggle Sidebar B
AppearanceLight & dark mode D

Count Up

Animated number counter supporting formatting and decimals.

Default

Every prop is wired to the controls underneath. The count starts once the number scrolls into view and replays when a control changes.

Dark previewReplay previewOpen in new tab
0

Customize

To100
From0
Duration1
Delay0
Direction

API Reference

CountUp

PropTypeDefaultDescription
tonumber-The target number to count up to.
fromnumber0The initial number from which the count starts.
directionstring"up"Direction of the count; can be "up" or "down". When this is set to "down", "from" and "to" become reversed, in order to count down.
delaynumber0Delay in seconds before the counting starts.
durationnumber2Duration of the count animation, based on the damping and stiffness configured inside the component.
startWhenbooleantrueControls whether the animation should start when the component is in view. If this is true, the count will start.
separatorstring""Character to use as a thousands separator in the displayed number.
startevent-Emitted when the count animation starts.
endevent-Emitted when the count animation ends.

Accessibility

Keyboard shortcuts and ARIA behavior.

  • The number is rewritten on every frame while it counts, so assistive tech may announce intermediate values. Render the final value in an aria-label when it matters.