PingNet is a real-time chat platform built using the MERN stack (MongoDB, Express.js, React.js, Node.js) and Socket.IO. It allows users to create accounts, send and receive private messages instantly, and enjoy a seamless chat experience across devices.
🔗 Click here to try the app live
- 🔒 Secure JWT Authentication
- 💬 Real-time messaging via Socket.IO
- 📥 Persistent chat history using MongoDB
- 🙍♂️ Private 1-on-1 messaging
- ✅ Online/offline user status indicator
- 🧠 Clean and responsive UI with Tailwind CSS
- 🔁 Auto scroll and smooth chat UX
- ⚡ Fast, efficient, and scalable
WebApp/
├── backend/ # Node.js + Express API
│ ├── controllers/
│ ├── models/
│ ├── routes/
│ └── config/
├── frontend/ # React.js Client
│ ├── components/
│ ├── pages/
│ └── utils/
└── README.md-
Clone the repository:
git clone (https://github.com/yogendradayal/WebApp) cd webchat-app -
Install the server dependencies:
cd backend npm install -
Install the client dependencies:
cd ../frontend npm install -
Create a
.envfile in theserverdirectory and add the following environment variables:MONGO_URI=your_mongo_database_uri JWT_SECRET=your_jwt_secret_key
-
Start the development server:
-
Server:
cd backend npm run dev -
Client:
cd frontend npm start
-
-
Open your browser and navigate to
http://localhost:3000to see the application in action.
- Users can sign up and log in using their email and password.
- JWT tokens are used to authenticate API requests.
- Messages are sent in real-time using Socket.io.
- Chat history is saved in MongoDB and is accessible when users reconnect.
To deploy the application:
- Set up a MongoDB database in a cloud service like MongoDB Atlas.
- Deploy the server to a cloud service like Heroku, Vercel, or AWS.
- Deploy the client to a static hosting service like Netlify or Vercel.
- Update the environment variables with your production values.
If you'd like to contribute to this project, feel free to fork the repository and submit a pull request. Please make sure to update tests as appropriate.




