Activity feed components

Powerful and customizable React activity feed components built for modern applications and websites. These activity feed components are built using React Aria and styled with Tailwind CSS.

Get the code

Installation

Some activity feeds components depend on other components to function properly. Before using them, make sure to add the required components via CLI.

Use the following command to install them:

npx untitledui@latest add activity-feed

Activity feed examples

Below are examples and variations of this activity feeds component:

Get the code
Get the code
Get the code
Get the code
  • Candice Wu
    Candice Wu

    @candice

    Great to see you again!

  • Natali Craig
    Natali Craig

    @natali

    We should ask Oli about this...

  • Drew Cano
    Drew Cano

    @drew

    Okay, see you then.

  • Orlando Diggs
    Orlando Diggs

    @orlando

    Datasheet_draft_02.pdf

    720 KB

  • Andi Lane
    Andi Lane

    @andi

    We should ask Oli about this...

  • Kate Morrison
    Kate Morrison

    @kate

    That sounds like a good plan!

  • Ava Wright
    Ava Wright

    @ava

    We should ask Oli about this today.

  • Eve Leroy
    Eve Leroy

    @eve

    Design screenshot.jpg

    720 KB

  • Zahir Mays
    Zahir Mays

    @zahir

    Thanks for helping out with that!

  • Joshua Wilson
    Joshua Wilson

    @joshua

    Hey I've sent everything off now. All done.

  • Rene Wells
    Rene Wells

    @rene

    Hey @olivia—just wanted to say thanks for your help on this. Really buried under!

Get the code
  • Candice Wu
    Candice Wu

    @candice

    Great to see you again!

  • Natali Craig
    Natali Craig

    @natali

    We should ask Oli about this...

  • Drew Cano
    Drew Cano

    @drew

    Okay, see you then.

  • Orlando Diggs
    Orlando Diggs

    @orlando

    Datasheet_draft_02.pdf

    720 KB

  • Andi Lane
    Andi Lane

    @andi

    We should ask Oli about this...

  • Kate Morrison
    Kate Morrison

    @kate

    That sounds like a good plan!

  • Ava Wright
    Ava Wright

    @ava

    We should ask Oli about this today.

  • Eve Leroy
    Eve Leroy

    @eve

    Design screenshot.jpg

    720 KB

  • Zahir Mays
    Zahir Mays

    @zahir

    Thanks for helping out with that!

  • Joshua Wilson
    Joshua Wilson

    @joshua

    Hey I've sent everything off now. All done.

  • Rene Wells
    Rene Wells

    @rene

    Hey @olivia—just wanted to say thanks for your help on this. Really buried under!

Get the code
  • Candice Wu
    Candice Wu

    @candice

    Great to see you again!

  • Natali Craig
    Natali Craig

    @natali

    We should ask Oli about this...

  • Drew Cano
    Drew Cano

    @drew

    Okay, see you then.

  • Orlando Diggs
    Orlando Diggs

    @orlando

    Datasheet_draft_02.pdf

    720 KB

  • Andi Lane
    Andi Lane

    @andi

    We should ask Oli about this...

  • Kate Morrison
    Kate Morrison

    @kate

    That sounds like a good plan!

  • Ava Wright
    Ava Wright

    @ava

    We should ask Oli about this today.

  • Eve Leroy
    Eve Leroy

    @eve

    Design screenshot.jpg

    720 KB

  • Zahir Mays
    Zahir Mays

    @zahir

    Thanks for helping out with that!

  • Joshua Wilson
    Joshua Wilson

    @joshua

    Hey I've sent everything off now. All done.

  • Rene Wells
    Rene Wells

    @rene

    Hey @olivia—just wanted to say thanks for your help on this. Really buried under!

API reference

FeedItem

Import FeedItem from @/components/application/activity-feed/activity-feed. Renders a <article> element.

FeedItem props
PropTypeDefaultDescription
id* (required)string | number—Unique identifier for the entry. Not rendered — use it as the React key when mapping over a feed.
user* (required){ avatarUrl: string; name: string; href: string; username?: string; status?: "online" | "offline"; }—The person the entry belongs to. Renders their avatar with an optional status dot, their name as a link to href, and an optional username line.
connectorboolean—Whether to draw a dotted vertical line below the avatar, joining this entry to the next one in the feed and adding spacing beneath it.
size
"sm""md"
"md"Size of the entry's avatar.
unseenboolean—Whether the entry is unread, which shows a green dot in the top-right corner of the item.
commentstring—Quoted text rendered in a <q> element below the header, for entries that represent a comment.
messagestring—Message body rendered in a bordered speech-bubble box at the bottom of the entry.
datestring—Timestamp shown beside the user's name, rendered in a <time> element and used as its dateTime value.
attachment{ name: string; size: string; type: "jpg" | "txt" | "pdf" | "mp4"; }—File attached to the entry. Renders a file type icon (light and dark variants) alongside the file's name and size.
labels{ name: string; color: BadgeColors; }[]—Tags rendered as a row of small badges under the header.
action{ content: string; target?: string; href?: string; }—What the user did, shown under their name. content is the sentence, and target renders after it as a link to href.

FAQs

Please refer to our frequently asked questions page for more.

Each item matches the exported FeedItemType: a required id and user object (avatarUrl, name, href, plus optional username and status), with optional date, action, comment, message, attachment, labels and unseen fields. Spread an item onto the component with <FeedItem {...item} />.

Pass connector={true} to FeedItem to render the dotted vertical line beneath its avatar. The connected examples compute it per item as connector={index !== feed.length - 1} so the last entry has no trailing line, while the divided and spaced examples pass connector={false}.

FeedItem accepts a size prop of "sm" or "md", and it defaults to "md". The size drives the avatar, rendering an "sm" avatar for "sm" and an "md" avatar otherwise.

Pass an attachment object with name, size and type, where type is one of "jpg", "txt", "pdf" or "mp4". The matching icon is rendered with FileIcon from @untitledui/file-icons, with separate light and dark variants.

Set unseen to true on the item. This renders a small success-colored dot in the top-right corner of that feed item.

Yes. Pass a labels array of { name, color } objects, where color is any BadgeColors value. Each label renders as a Badge at size="sm" inside an <aside aria-label="Labels"> element.

Each FeedItem renders as an <article>, timestamps use a <time dateTime={date}> element, and labels are grouped in a landmark labelled "Labels". Wrap the items in a <ul> with one <li> per item, as the examples do, so screen readers announce the feed as a list.