A simple WebRTC demo using PeerJS that showcases real-time video calls, screen sharing (with/without camera), and local video streaming between peers.
- 📹 One-to-one video calls
- 🖥️ Screen sharing (with or without camera access)
- 🎞️ Stream local video to remote peer
- 👥 Room-based peer connection system
Feature | Watch Demo |
---|---|
🔴 One-to-one Video Call | YouTube |
🖥️ Join Room & Share Screen | YouTube |
🚫 Screen Share w/o Camera | YouTube |
🎞️ Stream Local Video File | YouTube |
-
Clone the repository:
git clone https://github.com/Abhi5h3k/WebRTC-PeerJs-Demo.git cd WebRTC-PeerJs-Demo
-
Open index.html directly in your browser, or host the project using any static server.
-
Open the app in two different tabs or devices to test peer-to-peer connection.
- 📡 WebRTC (real-time communication)
- 🔌 PeerJS (simplified WebRTC peer connections)
- 🧠 HTML / CSS / JavaScript
WebRTC enables real-time audio, video, and data communication between browsers and devices. It works natively on all major browsers without the need for plugins. Supported by Google, Mozilla, Microsoft, and Apple, it's ideal for creating live chat, conferencing, or streaming apps.
PeerJS is a simple wrapper over WebRTC offering:
- Unique peer IDs
- Easy media stream and data channel creation
- Simplified connection logic between clients
PeerJS makes WebRTC development much easier and beginner-friendly.
Feel free to open an issue or contact me via LinkedIn if you have suggestions, bug reports, or questions.
This project is open source. Please maintain proper credits to the author and contributors when reusing or modifying