Stat CounterRive Number Counter Animation
A dashboard stat card: the number counts to its new value, the change chip turns green or red.
Get the file
Runtime
.rivReady to use in your app or website.
Free
Editable
.revOpen it in the Rive editor and change anything.
Free

Learn to build it
Full accessBuild this yourself, step by step. Every file in the library is included.
Courses from $119
Use it in your own products and client work. Please don't resell or share the files themselves.
Using this file
The licence →Can I use it in a commercial product or a client project?
Yes. Use it in your own apps, websites and games, and in work you do for clients, paid or not. Change it as much as you like. Read the full licence
Can I resell or share the file?
No. Please don't resell, redistribute or re-upload the files, as they are or changed, and don't bundle them into templates, asset packs or UI kits, free or paid. If someone wants one, share a link to this page instead. Read the full licence
Do I need to credit you?
No, credit isn't required. A mention or a link back is always appreciated, though. Read the full licence
What's the difference between the .riv and the .rev?
The .riv is the runtime file: it goes into your app or website and plays there. The .rev is the editable source: you open it in the Rive editor to change the design, the animation or the state machine, then export your own .riv. Read the full licence
I own a course. Do I get it?
Yes. If you own the Rive Masterclass or the Rive Scripting Course, every file in the library is yours, the .riv and the .rev. Sign in with the email you bought the course with and the downloads unlock. Read the full licence
Who owns the files?
The files stay © Tom Acco / Rive Masterclass. When you download or buy one, you get a licence to use it, not ownership of it. Read the full licence
Use it on your site
import { useRive } from '@rive-app/react-canvas';
export function Counter() {
const { rive, RiveComponent } = useRive({
src: '/counter.riv',
artboard: 'Counter',
stateMachines: 'State Machine',
autoplay: true,
autoBind: true,
});
// every input on this page is a view model property
const vm = rive?.viewModelInstance;
if (vm) vm.color('color').value = 0xFFFAFAF7;
return <RiveComponent style={{ width: '100%', height: 400 }} />;
}Inputs: value, prefix, suffix, label, delta, note, color, accent, card. All on the Counter view model.
How it's built
A stat card for a dashboard or an app: your label ("Followers") with a small trend icon, a big number that counts from the old value to the new one and lands with a pop, and a change chip that shows a green up arrow or a red down arrow from the sign of the change. Prefix, suffix, the note next to the chip and every colour come from data.
- 1It eases the data, not a timelineAn interpolator converter tweens every new value over one second, and a to-string converter keeps it whole on screen.
- 2The pop knows whenA trigger converter fires when the value changes, and the state machine lands the pop as the count finishes.
- 3The chip reads the signA state machine layer compares the change to zero and swaps the green up chip for the red down one. A multiply converter drops the minus sign, since the arrow already says it.


