Avatar

Data Display

User avatar with image loading, fallback text generation, status indicators, and shape variants

Basic Avatars

Legacy pattern using simple props for quick implementation.

Legacy Pattern (Simple Props)

User 1
User 2
User 3
User 4
Fallback User
Online User

Compound Avatars

Compound component pattern for maximum flexibility and control.

Compound Component Pattern

Judith Black
Broken Image
User 1
User 2
User 3
Online User
Ring User

Avatar Groups

Group multiple avatars together with simple or compound patterns.

Avatar Group

User 5
User 6
User 7
+2

Avatar Group Compound

User 5
User 6
User 7
+2

Sizes & Shapes

Control the visual hierarchy with size and shape variations.

Circle

User
User
User

Rounded

User
User
User

Square

User
User
User

Status & Presence

Combine avatars with subtle status indicators using badges.

Online user

Online

Shown with a green presence dot.

Busy user

Busy

Use color to represent different states.

Fallback & Initials

Show initials or a placeholder when the image is missing.

Initials

Jane Doe

Generic user

Avatar

Broken URL

Broken

Interactive Examples

Use avatars in cards, with labels, and interactive behaviors.

Jane Doe

Jane Doe

Pro

Product Designer • Remote

Usage Guidelines

When to Use

  • User profiles
  • Contact lists
  • Comment authors

Accessibility

  • Alt text describes the person
  • Decorative avatars use aria-hidden

Performance

  • Lazy image loading
  • Efficient fallback

Common Mistakes

  • No fallback for failed images
  • Missing alt text

Frequently Asked Questions

Avatar falls back to initials or a placeholder icon when the image fails.
Yes, Avatar can show online/offline/busy status indicators.

View on GitHub

See the full source code on GitHub