Skip to main content
FieldValue
ComponentsCometChatConversations, CometChatCallLogs, CometChatUsers, CometChatGroups
LayoutTabbed bottom navigation (Chats, Calls, Users, Groups)
PrerequisiteComplete Kotlin Integration or Jetpack Compose Integration Steps 1–3 first
PatternFull-featured messaging app with multiple sections
This guide builds a tabbed messaging UI — Chats, Calls, Users, and Groups tabs via bottom navigation, with each tab loading its CometChat component. This assumes you’ve already completed the integration guide for your chosen UI toolkit (project created, dependencies installed, init + login working).

What You’re Building

Two sections working together:
  1. Bottom navigation bar — switches between Chats, Calls, Users, and Groups
  2. Content area — renders the CometChat component for the active tab
This uses Android’s BottomNavigationView with Fragments: TabbedActivity hosts the navigation and fragment container, user taps a tab, the corresponding Fragment loads.

Step 1: Set Up the Tabbed Screen

Create a new Activity called TabbedActivity with BottomNavigationView.Layoutactivity_tabbed.xml:
activity_tabbed.xml
Menures/menu/bottom_nav_menu.xml:
bottom_nav_menu.xml
ActivityTabbedActivity.kt:
TabbedActivity.kt

Step 2: Create Tab Content

Create a Fragment for each tab. Each Fragment inflates a layout containing the corresponding CometChat component.ChatsFragment:
ChatsFragment.kt
fragment_chats.xml
CallLogsFragment:
CallLogsFragment.kt
fragment_call_logs.xml
UsersFragment:
UsersFragment.kt
fragment_users.xml
GroupsFragment:
GroupsFragment.kt
fragment_groups.xml
Download the navigation icons from the CometChat UI Kit repository and place them in your res/drawable/ directory.

Step 3: Launch the Tabbed Screen

Launch TabbedActivity from your MainActivity after successful login:
MainActivity.kt

Step 4: Register Activity & Permissions

Add the activity to your AndroidManifest.xml:
AndroidManifest.xml
Ensure you’ve added the required permissions in your AndroidManifest.xml:
AndroidManifest.xml
For call features, also add:
AndroidManifest.xml

Next Steps

Components Overview

Explore all available UI Kit components and their customization options

Theming

Customize colors, fonts, and styles to match your brand

Integration

Back to the main integration guide

Feature Guides

Add capabilities like threaded messages, blocking, and group management