Chat Connect is a real-time chat application built using React, Node.js, Express, Socket.IO, and MongoDB. This project allows users to communicate with each other instantly, with features such as user authentication, real-time messaging, and chat room management.
- Real-time messaging with Socket.IO
- Chat rooms
- Online status indicators
- Message timestamps
- Persistent chat history with MongoDB
You can find a live demo of the application here.
Ensure you have the following installed on your machine:
- Node.js
- npm or yarn
- MongoDB
git clone https://github.com/omjaisatya/chat-connect.git
cd chat-connect- Navigate to the server directory:
cd server- Install dependencies:
npm install- Create a .env file in the server directory and add the following:
PORT=5000
MONGO_URI=your_mongodb_connection_string- Start the backend server:
npm start- Navigate to the client directory:
cd ../client- Install dependencies:
npm install- Create a .env file in the client directory and add the following:
BACKEND_API_URL=http://localhost:5000- Start the frontend development server:
npm start- Open your browser and navigate to http://localhost:3000.
- Register a new account or login with an existing account.
- Create or join a chat room and start messaging in real-time.
- Frontend: React, Axios, Bootstrap
- Backend: Node.js, Express, Socket.IO
- Database: MongoDB
- Authentication: JWT (JSON Web Tokens)
chat-connect/
├── client/ # React frontend
│ ├── public/
│ ├── src/
│ ├── .env
│ ├── package.json
│ └── ...
├── server/ # Node.js backend
│ ├── models/
│ ├── .env
│ ├── server.js
│ ├── package.json
│ └── ...
├── README.md
└── ...
Contributions are welcome! Please follow these steps:
- Fork the repository.
- Create a new branch (git checkout -b feature/your-feature).
- Commit your changes (git commit -m 'Add some feature').
- Push to the branch (git push origin feature/your-feature).
- Open a pull request.