bitchat
bitchat copied to clipboard
BitChat is a real-time chat application made using MERN stack with user authentication. It allows multiple users to have a private and group chat.
🚀 Demo
This application is deployed on DigitalOcean. Please check it out :smile: here.

🖥️ Tech Stack
Frontend:
Backend:
Database:
Deployed On:
⚡️ Features
- [x] Real time communication is supported using Socket.io
- [x] Fully Responsive UI
- [x] User authentication using email with Login as well as Logout feature.
- [x] Passwords are encrypted.
- [x] Toast notifications for user actions.
- [x] Users can create group chat.
- [x] Typing Indicators while other user typing something.
📁 Project structure
├── client/
│ ├── public/
│ │ ├── favicon.ico
│ │ ├── index.html
│ │ ├── logo192.png
│ │ ├── logo512.png
│ │ ├── manifest.json
│ │ └── robots.txt
│ ├── src/
│ │ ├── animations/
│ │ │ └── typing.json
│ │ ├── components/
│ │ │ ├── Authentication/
│ │ │ │ ├── Login.jsx
│ │ │ │ └── Signup.jsx
│ │ │ ├── UserAvatar/
│ │ │ │ ├── UserBadgeItem.jsx
│ │ │ │ └── UserListItem.jsx
│ │ │ ├── miscellaneous/
│ │ │ │ ├── GroupChatModal.jsx
│ │ │ │ ├── ProfileModal.jsx
│ │ │ │ ├── SideDrawer.jsx
│ │ │ │ └── UpdateGroupChatModal.jsx
│ │ │ ├── ChatBox.jsx
│ │ │ ├── ChatLoading.jsx
│ │ │ ├── MyChats.jsx
│ │ │ ├── ScrollableChat.jsx
│ │ │ ├── SingleChat.jsx
│ │ │ └── index.js
│ │ ├── config/
│ │ │ └── ChatLogics.js
│ │ ├── context/
│ │ │ └── ChatProvider.js
│ │ ├── pages/
│ │ │ ├── Chat.jsx
│ │ │ ├── Home.jsx
│ │ │ └── index.js
│ │ ├── App.css
│ │ ├── App.js
│ │ └── index.js
│ └── package.json
├── config/
│ ├── connectToMongoDb.js
│ ├── generateHashedPassword.js
│ ├── generateToken.js
│ ├── index.js
│ └── verifyPassword.js
├── controllers/
│ ├── chatControllers.js
│ ├── index.js
│ ├── messageControllers.js
│ └── userControllers.js
├── middleware/
│ ├── authMiddleware.js
│ ├── errorMiddleware.js
│ └── index.js
├── models/
│ ├── Chat.js
│ ├── Message.js
│ ├── User.js
│ └── index.js
├── routes/
│ ├── chatRoutes.js
│ ├── index.js
│ ├── messageRoutes.js
│ └── userRoutes.js
├── .env.example
├── .gitignore
├── LICENSE
├── package-lock.json
├── package.json
├── README.md
└── server.js
📖 Prerequisites
In order to run the project you need node>=16 and npm>=8 installed on your machine.
🚩 Getting Started
1. Clone the bitchat repository:
git clone https://github.com/rtewari056/bitchat.git
2. Navigate into repo:
cd bitchat
3. Rename .env.example into .env and put all creadentials:
PORT=5000
MONGO_URI="YOUR_MONGO_CONNECTION_URL"
JWT_SECRET="YOUR_JWT_SECRET"
JWT_EXPIRE=2d
NODE_ENV=development # Change to "production" when deploying
4. Install package dependencies:
npm install # Server dependencies
cd client
npm install # Client dependencies
4. Run project:
In the root directory, open two terminal sessions and run both commands separately:
npm run client
npm run server
5. Open your browser and go to http://localhost:3000
👤 Developer
📬 Contact
If you want to contact me, you can reach me through below handles.
📃 License
bitchat is licensed under the MIT License.