Reechdesk

ChatWidget

Floating chat bubble with real-time messaging, agent avatars, offline support, and paste media.

Live Preview — Chat Widget

Usage

app/page.tsxtsx
import { ChatWidget } from '@reechdesk/sdk';

export default function Home() {
  return (
    <main>
      <h1>Welcome to my app</h1>

      <ChatWidget
        position="bottom-right"
        primaryColor="#f26522"
        greeting="Hi {name}, how can we help?"
        entityName="Acme Support"
        poweredBy={true}
      />
    </main>
  );
}

Props

PropTypeDescription
position'bottom-right' | 'bottom-left'Position of the chat bubble on screen.
primaryColorstringBrand color used for the chat bubble, header, and user messages.
greetingstringInitial message shown when the chat opens. Supports {name} placeholder.
entityNamestringName displayed in the chat header.
logoUrlstring | nullURL of the logo shown in the chat header.
borderRadiusnumberBorder radius of the chat window in pixels.
inputBorderRadiusnumberBorder radius of the message input field.
poweredBybooleanShow "Powered by Reechdesk" badge at the bottom of the chat.
soundEnabledbooleanPlay a notification sound when a new message arrives.

Features

Agent Avatars

Shows agent photos and online status in the chat header and messages.

Online/Offline Status

Displays agent count when online, or a "Leave a message" form when offline.

Paste Media

Visitors can paste images and files directly into the chat input.

Resume from URL

Automatically resumes existing sessions via ?chat=resume&id=xxx.

Personalized Greeting

Use {name} or {Name}in the greeting to insert the visitor's name.

tsx
<ChatWidget
  greeting="Hi {name}, how can we help you today?"
  // When user.name = "Sarah", renders:
  // "Hi Sarah, how can we help you today?"
/>

Requires HelpdeskProvider

The ChatWidget must be rendered inside a HelpdeskProvider. See the HelpdeskProvider docs for setup.