Join our Discord Community
Avatar/Standard

React Avatar with Count Indicator

A circular avatar with a red notification count badge showing unread messages or pending actions

Looking to implement shadcn/ui patterns?

Join our Discord community for help from other developers.


That little red bubble with a number on messenger apps—it demands attention and drives engagement. This React avatar adds a notification count badge positioned at top-right with -right-2 -top-2, using bg-red-500 for urgency and text-white for contrast. Built with shadcn/ui and Radix UI, the badge includes border-background separation and font-medium text-xs for readability. Perfect for chat applications showing unread message counts, inbox interfaces, notification centers, or any scenario where quantifying pending items motivates user action.

Loading preview...

Pattern created by @haydenbleasel

Installation

npx shadcn@latest add https://www.shadcn.io/registry/avatar-standard-7.json
npx shadcn@latest add https://www.shadcn.io/registry/avatar-standard-7.json
pnpm dlx shadcn@latest add https://www.shadcn.io/registry/avatar-standard-7.json
bunx shadcn@latest add https://www.shadcn.io/registry/avatar-standard-7.json

Questions you might have