A Discord-inspired, full-stack real-time chat platform for modern communities. Channels, direct messaging, voice/music lounges, role-based moderation, and a full admin panel β all in one app.
| Part | Repository |
|---|---|
| π₯οΈ Frontend | github.com/sabeenaviklar/PingUp-Frontend |
| βοΈ Backend | github.com/sabeenaviklar/PingUp-Backend |
PingUp is a real-time community chat platform that brings people together through organized channels, direct messaging, and shared music experiences. It was built from scratch using React, Node.js, Socket.IO, and MongoDB.
Think of it as a lightweight, self-hostable Discord β with a clean forest-green aesthetic, a Stranger Things music lounge, and a powerful owner panel to manage your community in real time.
- Instant messages delivered via WebSockets (Socket.IO) β zero page refreshes
- Live typing indicators with animated bouncing dots
- Message pinning β moderators can pin important messages, visible at the top of every channel
- Soft message deletion β deleted messages show
[message deleted]rather than disappearing - Auto-scroll to latest message on new activity
- Channels are organized inside collapsible categories (exactly like Discord)
- Owners can create, delete, and rename channels and categories live β all users see updates instantly
- Each channel supports a custom emoji and description
- Per-channel toggleable settings:
- π Read-only β only owners can send messages
- π Locked β no one can send messages
- ποΈ Private β only specific users can see and join
- Channel status badges displayed in the header and sidebar
- A special Stranger Things themed music lounge channel
- Built-in YouTube-powered audio player β no API key required
- Playlist of 5 tracks:
- π Stranger Things β Main Theme (Kyle Dixon & Michael Stein)
- π΄ Running Up That Hill (Kate Bush)
- β‘ Should I Stay or Should I Go (The Clash)
- π Every Breath You Take (The Police)
- π₯ Master of Puppets (Metallica)
- Discord-style lobby screen before joining β shows who's listening
- Animated spinning album art with per-track colour theming
- Real-time listening members panel with sound wave animations
- Previous / Stop / Next controls + volume slider + mute toggle
PingUp has a strict 3-tier role system:
| Role | Badge | Capabilities |
|---|---|---|
| π Owner | Gold | Everything β full server control |
| π‘οΈ Moderator | Teal | Delete/pin messages, kick members |
| π€ Member | Grey | Send messages, read channels |
- The first user to register is automatically made Owner
- Roles are enforced server-side β the client UI only reflects server decisions
- Role-coloured avatars, username colours, and pills throughout the entire UI
- Private 1-on-1 conversations between any users
- Persistent message history stored in MongoDB
- Unread message badges on the DM list
- Toast pop-up notifications for incoming DMs while in a channel
- Live typing indicators in DM conversations
- Click any username in the member panel to open a DM
- Full server statistics: total users, online count, messages, channels
- User management table: see all users, change roles, kick, or ban
- Channel management: create/delete channels, toggle read-only/lock/private
- All changes take effect instantly across all connected clients
Type /help in any channel for a full command list:
| Command | Who | What it does |
|---|---|---|
/help |
All | Show all commands |
/online |
All | List currently online users |
/whoami |
All | Show your profile details |
/rooms |
All | List all channels and their status |
/kick <username> |
Mod+ | Kick a user from the server |
/pin <messageId> |
Mod+ | Pin or unpin a message |
/delete <messageId> |
Mod+ | Delete a message |
/promote <user> <role> |
Owner | Set a user's role |
/ban <username> |
Owner | Permanently ban a user |
/reroll <username> |
Owner | Randomly re-assign a user's role |
/newchannel <cat> <name> |
Owner | Create a new channel in a category |
/delchannel <name> |
Owner | Delete a channel |
/renamechannel <old> <new> |
Owner | Rename a channel |
/newcategory <name> |
Owner | Create a new category |
/readonly <channel> |
Owner | Toggle read-only on a channel |
/lock <channel> |
Owner | Toggle lock on a channel |
/private <channel> |
Owner | Toggle private on a channel |
/clear |
Owner | Wipe all messages in the current channel |
/stats |
Owner | View server statistics |
| Layer | Technology | Why |
|---|---|---|
| Frontend | React 18 + Vite | Fast, component-based UI with HMR |
| Styling | Pure CSS3 (custom design system) | Full control, no utility class bloat |
| Backend | Node.js + Express.js | Lightweight, fast REST API |
| Real-time | Socket.IO 4.x | Bi-directional WebSocket events |
| Database | MongoDB + Mongoose | Flexible schema for messages/users |
| Auth | JWT (JSON Web Tokens) | Stateless, scalable authentication |
| Audio | YouTube iFrame embed | No API key, browser-native playback |
PingUp/
β
βββ PingUp-Frontend/ # React + Vite client
β βββ public/
β βββ src/
β βββ components/
β β βββ DMSidebar.jsx # Left sidebar β channels, categories, user bar
β β βββ MessageList.jsx # Chat message feed with pinning/deletion
β β βββ MessageInput.jsx # Message compose bar with typing events
β β βββ UserPanel.jsx # Right sidebar β member list with roles
β β βββ VoiceChannel.jsx # Stranger Things music lounge player
β β βββ DMChat.jsx # Direct message chat window
β β βββ DMList.jsx # DM conversation list panel
β β βββ AdminPanel.jsx # Owner admin dashboard
β β βββ FriendsPanel.jsx # Friends & online users view
β β βββ ProfileModal.jsx # User profile edit modal
β β βββ Login.jsx # Login page
β β βββ Register.jsx # Registration page
β βββ App.jsx # Root component β socket wiring, routing logic
β βββ socket.js # Socket.IO client singleton
β βββ index.css # Full design system (CSS variables + all styles)
β βββ main.jsx # React entry point
β
βββ PingUp-Backend/ # Node.js + Express server
βββ models/
β βββ User.js # User schema: role, banned, online, loginCount
β βββ Room.js # Channel schema: isPrivate, isReadOnly, isLocked, isVoice
β βββ Message.js # Message schema: pinned, deleted, roomName
β βββ DirectMessage.js # DM schema: conversationId, read, participants
βββ middleware/
β βββ auth.js # JWT sign/verify + socket auth middleware
βββ server.js # Main file: Express routes + Socket.IO handlers
βββ .env # Environment variables (not committed)
βββ package.json
Make sure you have the following installed:
- Node.js v18 or higher β download here
- npm v9+ (comes with Node.js)
- MongoDB Atlas account (free tier works) β sign up here
- Git β download here
Open your terminal and run:
# Clone the frontend
git clone https://github.com/sabeenaviklar/PingUp-Frontend.git
# Clone the backend
git clone https://github.com/sabeenaviklar/PingUp-Backend.gitYou'll now have two folders: PingUp-Frontend/ and PingUp-Backend/
- Go to mongodb.com/atlas and sign in
- Create a free cluster (M0 tier)
- Under Database Access β Add a new database user with username & password
- Under Network Access β Add
0.0.0.0/0(allow all IPs) for development - Click Connect β Connect your application β Copy the connection string
It will look like:
mongodb+srv://youruser:yourpassword@cluster0.xxxxx.mongodb.net/pingup
cd PingUp-Backend
npm installCreate a .env file in the PingUp-Backend/ folder by copying the example:
# PingUp-Backend/.env (copy from .env.example)
cp .env.example .envThen set your real values in PingUp-Backend/.env:
MONGO_URI: your MongoDB Atlas connection stringJWT_SECRET: a strong, unique secret (rotate if it was ever exposed)PORT: server port (e.g.3001)
β οΈ Never commit.envto GitHub. This repo includesPingUp-Backend/.env.examplewith placeholder values.
β οΈ Never commit.envto GitHub. Make sure it's in your.gitignore.
Start the backend server:
npm run dev OR node server.jsYou should see:
β
MongoDB connected
β
Default rooms seeded
π Server on http://localhost:3001
Open a new terminal window, then:
cd PingUp-Frontend
npm installCreate a .env file in the PingUp-Frontend/ folder:
# PingUp-Frontend/.env
VITE_API_URL=http://localhost:3001
VITE_SOCKET_URL=http://localhost:3001Start the frontend:
npm run devYou should see:
VITE v5.x.x ready in xxx ms
β Local: http://localhost:5173/
- Open http://localhost:5173 in your browser
- Click Register and create your first account
- β The first user to register is automatically made Owner
- Open a second browser tab or incognito window and register another user
- This user will be a Member
- You can now chat between the two accounts in real time!
| Feature | How to test |
|---|---|
| Real-time chat | Send messages from two different browser windows |
| Typing indicator | Start typing in one window β see it appear in the other |
| Owner panel | Log in as the first user β click Admin Panel in the sidebar |
| Music lounge | Click #music-lounge in the sidebar β Join Lounge β pick a track |
| Direct messages | Click any online user in the right panel β start a DM |
| Slash commands | Type /help in any channel |
| Channel settings | As owner, click the π π ποΈ buttons in the channel header |
| Role management | Admin Panel β Users β change a user's role |
| Method | Endpoint | Auth | Description |
|---|---|---|---|
POST |
/api/register |
β | Register new user |
POST |
/api/login |
β | Login, receive JWT token |
GET |
/api/structure |
β JWT | Get categories + channels |
GET |
/api/rooms |
β | Get all rooms (legacy) |
GET |
/api/users |
β Mod+ | Get all users |
PUT |
/api/profile |
β JWT | Update profile info |
GET |
/api/dm/:otherUserId |
β JWT | Get DM history |
GET |
/api/dm |
β JWT | Get all DM conversations |
Client β Server:
channel:join { channelId }
message:send { channelId, text }
typing:start { channelId }
typing:stop { channelId }
message:pin { channelId, messageId }
message:delete { channelId, messageId }
channel:create { categoryId, name, emoji, description }
channel:delete { channelId }
channel:toggleReadOnly { channelId }
channel:toggleLock { channelId }
channel:togglePrivate { channelId }
category:create { name }
category:delete { categoryId }
user:setrole { targetId, role }
user:kick { targetId }
user:ban { targetId }
voice:join { channelId }
voice:leave { channelId }
dm:join { otherUserId }
dm:send { toUserId, text }
Server β Client:
structure:update β full category/channel tree refreshed
users:update β online users list changed
channel:history β message history for joined channel
message:new β new message arrived
message:deleted β message was deleted
message:pinned β message was pinned
message:unpinned β message was unpinned
room:settings β channel settings changed
room:notification β system message (join/leave/kick/etc.)
typing:update β typing status changed
role:updated β your own role was changed
kicked β you were kicked or banned
voice:joined β someone joined the voice channel
voice:left β someone left the voice channel
voice:members β current voice members list
dm:message β new direct message received
dm:notification β toast notification for new DM
- Passwords hashed with bcrypt (10 salt rounds) β never stored in plain text
- All protected routes require a valid JWT Bearer token in the
Authorizationheader - Every Socket.IO connection is authenticated via JWT middleware at connection time
- Banned users are rejected at both the REST API and WebSocket level
- All permission checks (kick, ban, promote, toggle channel settings) are enforced server-side only β the client UI is cosmetic and cannot bypass server rules
- Private channel access verified on every
channel:joinevent
PingUp uses a custom forest/sage green dark theme built entirely in CSS variables:
--bg-primary: #1a2a22 /* Deep forest background */ --bg-secondary: #1e2f26
/* Sidebar backgrounds */ --bg-elevated: #243322
/* Cards, inputs, elevated surfaces */ --accent: #4a9e8e
/* Teal green β buttons, active states */ --accent-hover: #5ab5a4
/* Accent on hover */ --accent-muted: rgba(74, 158, 142, 0.12)
/* Soft accent backgrounds */ --urgent: #bc6c25
/* Warm amber β warnings, danger */ --text-primary: #e8f0ec
/* Main text β soft white */ --text-muted: #7a9e8a
/* Secondary text β muted sage */;The Music Lounge overrides these with per-track dynamic gradients based on the currently playing song.
| **Sabeena
NOTE: For admin login, the username : josh and password : 1234
This project is licensed under the MIT License. See the LICENSE file for details.
- Discord β UI/UX inspiration
- Socket.IO β Real-time WebSocket engine
- MongoDB Atlas β Cloud database
- Vite β Blazing fast frontend tooling
- Kate Bush β Running Up That Hill π΅
- Kyle Dixon & Michael Stein β Stranger Things Theme π
π’ PingUp β Ping your people, build your community.
Frontend Β·
Backend
deployed link: https://pingupsite.onrender.com
Backend API: https://pingup-backend-1.onrender.com