Skip to content

WebRTC plugin

Daniel Neto edited this page Oct 7, 2026 · 14 revisions

WebRTC plugin

The WebRTC plugin lets users go live from the browser webcam (or screen) with one click, without OBS. It runs a small server program, WebRTC2RTMP, that receives the browser video and sends it to your live server as a normal RTMP stream. The plugin is free and included in AVideo.

Requirements

  • The Live plugin with a working live server.
  • The Scheduler plugin with its cron job: the Scheduler starts the WebRTC2RTMP server and restarts it if it stops.
  • HTTPS on your site: browsers only open the camera on secure pages.
  • TCP port 3000 (or the port you set) open in the server and hosting firewalls. Browsers connect to https://your-domain:3000.

Enable it

  1. Open Admin Panel → Plugins and enable Live, Scheduler and WebRTC.

  2. Advanced (server access needed): if the Scheduler cron is not installed yet, open a terminal on the server (SSH) and paste:

    ( sudo crontab -u www-data -l 2>/dev/null | grep -v 'plugin/Scheduler/run.php'; echo "* * * * * php /var/www/html/AVideo/plugin/Scheduler/run.php" ) | sudo crontab -u www-data -
  3. Wait about one minute. The Scheduler starts WebRTC2RTMP.

  4. In the plugin list, click Server Status on the WebRTC row to check it.

Settings

In Admin Panel → Plugins, WebRTC row, Edit parameters:

Setting Default What it does
port 3000 Port of the WebRTC2RTMP server. Open it in the firewall.
autoStartServerIfIsInactive on The Scheduler starts the server again when it is not running.
Enable Quick Go Live on Shows a one-click Go Live button in the top menu.
Quick Go Live Button Title Go Live Text of that button.

How to use it

Users with live permission (Can Stream Videos) can:

  • click Go Live in the top menu, or
  • open the live page (LIVE button) and choose the Webcam tab. The Stream Software tab still shows the OBS settings.

Webcam broadcast

Go Live in the menu

Free and premium

The Server Status page shows the limits of your WebRTC2RTMP server: Max RTMP Runtime (minutes per broadcast), Max Concurrent RTMP (simultaneous broadcasts) and Premium Features. Without premium, broadcasts carry a watermark and have lower limits. The Upgrade to Premium button there opens the WebRTC2RTMP marketplace page.

The server uses CPU, memory and bandwidth for every browser broadcast. Test with your expected number of simultaneous broadcasters.

Check the server

Click Server Status on the WebRTC row in the plugin list. It shows the port, domain, version, last activity, whether the port is open inside and outside the server, whether the server file is executable, and the server log.

Server Status button

Server Status page

Stop, update and restart the server by hand

Advanced (server access needed). This stops the server, installs the WebRTC2RTMP version shipped with your AVideo files, and starts it again, as the same user as the Scheduler cron:

sudo -u www-data php /var/www/html/AVideo/plugin/WebRTC/tools/forceAll.php

The server log is /var/www/html/AVideo/videos/WebRTC2RTMP.log.

Problems

Problem What to check
Server Status shows the server inactive The Scheduler plugin is enabled and its cron runs; wait one minute; run the command above and read the log.
Port open only inside the server Open port 3000 (TCP) in the server firewall and in the hosting provider firewall.
"File is not executable" The plugin copies plugin/WebRTC/assets/WebRTC2RTMP to plugin/WebRTC/WebRTC2RTMP and makes it executable, so the plugin folder must belong to www-data (the Ubuntu install guide sets this). Then run the command above.
The camera does not open Use HTTPS and allow the camera in the browser.
Go Live is missing The user needs Can Stream Videos; Enable Quick Go Live must be on.
The update failed Follow If the update fails.

Clone this wiki locally