Skip to content

Avatar ​

A person's picture, or their initials on a primary circle, optionally with a profile card on hover.

Open in Storybook to try every prop.

When to use ​

Use an Avatar forUse instead
Showing who someone is beside their name, or in place of itSeveral people together (AvatarGroup)
A quick look at someone's details (profile) without leaving the pageFull details (link to their profile page)

Anatomy ​

PartRequiredNotes
circleYesPrimary fill, white bold initials, or the picture filling it.
pictureNouser.avatar. Falls back to initials if it fails to load.
profile cardNoWith profile: a popover with organisation, a 48px avatar, name, role and email (a mailto link).

Properties ​

PropertyTypeDefaultDescription
user—Required. Initials come from the first and last words of name.
sizexs | sm | md | lg | xlmdSee Sizes.
profilebooleanfalseShow the profile card on hover, click, tap or Enter. Makes the avatar a button.
decorativebooleanfalseHidden from screen readers, when the name is already said nearby.

Sizes ​

SizeDiameterInitials
xs20px12px bold
sm28px12px bold
md36px14px bold
lg48px16px bold
xl64px20px bold

Profile card: 256px wide; avatar 48px; name 14px bold; role and email 14px, black 65%; organisation 12px bold uppercase, black 65%.

States ​

StateAppearanceNotes
PicturePicture, cropped to the circle
No picture / failedInitials on primary
Focused (profile)2px focus ring #007FC9, 1px outsideKeyboard only
Profile openCard below, aligned to the startOpens after 300ms hover, closes 150ms after leaving

Behaviour ​

ActionResult
Hover (profile)Card opens after 300ms; stays while the pointer is on it
Click, tap or Enter (profile)Card opens; focus stays on the avatar
Escape or click outsideCard closes

Accessibility ​

CaseAnnounced as
No profileimg named by the person's name
DecorativeHidden
Profile, with initialsButton named "{initials}, {name}" (visible text first, for voice control)
Profile, with a pictureButton named "{name}"

Initials on primary: white on #023750 is 12.1:1.

Platform adaptation ​

PlatformImplementationDifferences
Web / desktop (Vue)Avatar.vue—
iOS (SwiftUI)—Circle-clipped AsyncImage with an initials fallback; profile in a popover (iPad) or sheet (iPhone).
Android (Compose)—Circle-clipped image with an initials fallback; profile in a bottom sheet.

Tokens used ​

TokenUsed for
color primarycircle background
color whiteinitials
color focusfocus ring

Do / Don't ​

DoDon't
Use decorative when the name is beside itLeave screen readers hearing the name twice
Use profile where people want a quick lookPut actions (message, edit) only in the profile card

Released under the PolyForm Noncommercial License 1.0.0.