An open API service indexing awesome lists of open source software.

https://github.com/uddipta7/pingchat-realtime

โšก PingChat is a full-stack real-time 1:1 chat app built with React, Node.js, Socket.io, and MongoDB. It features live messaging, typing indicators, JWT auth, Cloudinary uploads, and a clean responsive UI with Tailwind CSS.
https://github.com/uddipta7/pingchat-realtime

chat-app jwt-auth mern-stack react real-time socket-io

Last synced: about 2 months ago
JSON representation

โšก PingChat is a full-stack real-time 1:1 chat app built with React, Node.js, Socket.io, and MongoDB. It features live messaging, typing indicators, JWT auth, Cloudinary uploads, and a clean responsive UI with Tailwind CSS.

Awesome Lists containing this project

README

          

# ๐Ÿ’ฌ PingChat โ€” Real-Time Messaging Redefined

**PingChat** is a lightning-fast, full-stack real-time chat application built with the power of **Socket.io** and the modern MERN stack. Whether you're chatting with friends or building the next-gen messenger, PingChat brings you the tools and experience you need โ€” secure, scalable, and stylish.

---

## โšก Features at a Glance

โœ… 1:1 **Real-Time Messaging** with Socket.io
๐Ÿ” **User Authentication** using JWT
๐Ÿง  **Redux Toolkit** for seamless state management
๐Ÿ—‚๏ธ **MongoDB + Mongoose** for user & chat persistence
๐Ÿ–ผ๏ธ **Cloudinary Image Uploads** for profile pictures and media
โœ๏ธ **Live Typing Indicators**
๐ŸŸข **Online/Offline Status**
๐Ÿ“ฑ **Fully Responsive Design** โ€” Mobile + Desktop ready
๐ŸŽจ Built with sleek **Tailwind CSS** styling

---

## ๐Ÿงฐ Tech Stack

**Frontend:**
- React.js
- Redux Toolkit
- Axios
- Tailwind CSS

**Backend:**
- Node.js
- Express.js
- MongoDB with Mongoose
- Socket.io
- JSON Web Tokens (JWT)
- Cloudinary API

---

## ๐Ÿš€ Getting Started

### ๐Ÿงพ Prerequisites

- Node.js (v14+)
- MongoDB (local or Atlas)
- A Cloudinary account

---

### ๐Ÿ”ง Installation

#### 1. Clone the repository:

```bash
git clone https://github.com/your-username/pingchat-app.git
cd pingchat-app
```
#### 2. Backend Setup
```bash
cd backend
npm install
```
Create a .env file in /backend with the following:

```env
PORT=5000
MONGO_URI=your_mongodb_connection_uri
JWT_SECRET=your_jwt_secret
CLOUDINARY_CLOUD_NAME=your_cloud_name
CLOUDINARY_API_KEY=your_api_key
CLOUDINARY_API_SECRET=your_api_secret
```

Start the backend server:

```bash
npm run dev
```
#### 3. Frontend Setup
```bash
cd ../frontend
npm install
npm start
```

### ๐Ÿ“ Project Structure
```php

pingchat-app/
โ”œโ”€โ”€ backend/ # Node.js + Express backend
โ”‚ โ”œโ”€โ”€ config/ # DB and cloudinary config
โ”‚ โ”œโ”€โ”€ controllers/ # Route handler logic
โ”‚ โ”œโ”€โ”€ middlewares/ # Auth, error handling, etc.
โ”‚ โ”œโ”€โ”€ models/ # Mongoose schemas (User, Chat, Message)
โ”‚ โ”œโ”€โ”€ public/ # Static assets if any
โ”‚ โ”œโ”€โ”€ routes/ # API endpoints (user, chat, message)
โ”‚ โ”œโ”€โ”€ socket/ # Socket.io real-time logic
โ”‚ โ”œโ”€โ”€ .env # Environment variables
โ”‚ โ”œโ”€โ”€ index.js # Entry point of the backend
โ”‚ โ””โ”€โ”€ package.json # Backend dependencies
โ”‚
โ”œโ”€โ”€ frontend/ # React + Vite + Redux frontend
โ”‚ โ”œโ”€โ”€ public/ # Static files
โ”‚ โ”œโ”€โ”€ src/
โ”‚ โ”‚ โ”œโ”€โ”€ assets/ # Icons, images, etc.
โ”‚ โ”‚ โ”œโ”€โ”€ components/ # Reusable UI components
โ”‚ โ”‚ โ”œโ”€โ”€ context/ # React context providers
โ”‚ โ”‚ โ”œโ”€โ”€ customHooks/ # Custom reusable hooks
โ”‚ โ”‚ โ”œโ”€โ”€ pages/ # Main pages (Chat, Login, Signup, etc.)
โ”‚ โ”‚ โ”œโ”€โ”€ redux/ # Redux slices and store setup
โ”‚ โ”‚ โ”œโ”€โ”€ App.jsx # Root component
โ”‚ โ”‚ โ”œโ”€โ”€ index.css # Global styles
โ”‚ โ”‚ โ””โ”€โ”€ main.jsx # React app entry point
โ”‚ โ”œโ”€โ”€ tailwind.config.js # TailwindCSS config
โ”‚ โ”œโ”€โ”€ vite.config.js # Vite bundler config
โ”‚ โ””โ”€โ”€ package.json # Frontend dependencies
โ”‚
โ”œโ”€โ”€ .gitignore
```
### ๐Ÿ”’ Security & Performance
- JWT-based route protection for authenticated endpoints

- Efficient socket connection management

- Cloudinary for secure and scalable image storage

### ๐Ÿ“„ License
This project is licensed under the MIT License โ€” feel free to use, modify, and share!