A lightweight Discord clone built to learn Node.js, Express, Socket.IO, and PostgreSQL.
- Google OAuth2 Login: Passwordless auth handled on the server.
- Real-time Messaging: WebSockets powered by Socket.IO.
- Session Security: Session IDs stored in
HttpOnlyandSameSitecookies, reducing the risk of session theft through XSS. - Persistent Data: Message history saved in PostgreSQL.
- API Protection: Rate limiting on auth endpoints to prevent spam.
- Server: Node.js, Express.js, Socket.IO, express-session
- Database: PostgreSQL
- Auth: Google Auth Library (
google-auth-library) - Frontend: HTML, CSS, Vanilla JS
- Node.js (v18+)
- PostgreSQL
- Google Cloud Console Client ID
git clone https://github.com/Antidino72/DiscordLite
cd discord-lite
//modifie .env.exemple to .env and modify entry
npm install
npm start
and Open http://localhost:3000 in your browser.
- Google OAuth2 & Secure Cookies
- Real-time messaging
- Message history (PostgreSQL)
- Session cleanup / Logout
- Online members list & status
- Smart auto-scroll & sound notifications
- Markdown parsing
- Image & link previews
- Mobile responsive
check .env.exemple
Work in progress

