A real-time chat platform built with modern technologies featuring instant messaging, smooth infinite scrolling, and scalable backend architecture.

Real-time push notification using Firebase cloud Messaging(FCM)
Efficient rendering of large message lists using virtualization for smooth performance.
Messages appear instantly using React Query’s optimistic updates before server confirmation.
Upload and share images/Video with cloud storage integration for scalability and speed.
Event driven websocket updates with debounced typing signal and live presence traking
Supports one-to-one and group chats with message status indicators like sent, delivered, and seen with reaction and reply function
Users appeared online/offline inconsistently due to multiple socket connections and refresh events.
Solution
Used Map-based socket tracking + emit only after stable connect/disconnect state.
Chat data was being refetched on every chat open causing unnecessary API calls and UI flicker.
Solution
Fixed using React Query caching with proper query keys and staleTime to reuse existing data instead of refetching
Users were logged out immediately when access token expired.
Solution
Implemented refresh token flow for silent re-authentication without interrupting session.
On mobile back navigation, users were incorrectly redirected to login due to auth state mismatch.
Solution
Fixed using persistent JWT auth check with protected routes and synced global auth state (React Context/React Query).
Users remained online after tab close due to unstable disconnect events.
Solution
Added debounce (setTimeout) + proper cleanup of socket IDs in Map.
Chatted users list API was slow due to inefficient queries and multiple database lookups on each request.
Solution
Optimized using MongoDB aggregation pipeline to reduce joins and fetch required data in a single query, significantly improving response time.
React + Context API
Node.js + Express + JWT
MongoDB + Mongoose
Users + Messages + Conversations
Send + Optimistic UI
JWT + Express API
MongoDB Atlas Save
Socket.IO
FCM Push
React Query Update
ChatNova
Access Token used
JWT + bycrpyt
Access Token Expired
Send Refresh Token
Auto regenerated
Request succeeds
Api Succeed
Socket.IO • JWT Auth • MongoDB • React

Socket powered messaging

Message Status, Message Reactions

Secure login system

Multi-user conversations

Live User Tracking

Mobile optimized design
Integrating Redis Pub/Sub to scale Socket.IO across multiple servers, enabling seamless real-time messaging, presence sync, and low-latency communication even under high traffic load.
Implementing peer-to-peer audio and video calling using WebRTC with secure signaling via Socket.IO for low-latency one-to-one and group communication.
Implementing role-based access control in group chats to support Admin, Moderator, and Member roles for better control and moderation.
Implementing asynchronous end-to-end encryption to ensure only sender and receiver can read messages, improving chat security.
Integrating AI-based suggestion system to recommend smart replies, message completions, and contextual responses in real time.
Adding advanced message deletion allowing users to remove messages locally or for all participants in a conversation.