> ## Documentation Index
> Fetch the complete documentation index at: https://cometchat-013b37f0.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Badge

The `CometChatBadge` component displays the unread count of messages for one-to-one private and group chats.

***

## Methods

| Methods                          | Description                                                |
| -------------------------------- | ---------------------------------------------------------- |
| `set(borderColor : UIColor)`     | Sets the `borderColor` for `CometChatBadgeCount` class     |
| `set(borderWidth : CGFloat)`     | Sets the `borderWidth` for `CometChatBadgeCount` class     |
| `set(backgroundColor : UIColor)` | Sets the `backgroundColor` for `CometChatBadgeCount` class |
| `set(textColor : UIColor)`       | Sets the `textColor` for `CometChatBadgeCount` class       |
| `set(textFont : UIFont)`         | Sets the `textFont` for `CometChatBadgeCount` class        |
| `set(cornerRadius : CGFloat)`    | Sets the `cornerRadius` for `CometChatBadgeCount` class    |
| `set(count : Int)`               | Sets the `count` for `CometChatBadgeCount` class           |
| `incrementCount()`               | Used to increment `count`                                  |
| `removeCount()`                  | Used to clear `count`                                      |

***

## Uses

<Tabs>
  <Tab title="Swift">
    ```swift theme={null}
    unreadCount.set(backgroundColor: .red)
               .set(count: 20)
    ```
  </Tab>
</Tabs>
