Jitsi was one of the first open-source WebRTC projects. It evolved out of SIP client software into a Selective Forwarding Unit (SFU) before evolving into a full-fledged meetings platform. In the nearly 20 years since was started, it has amassed 140 open source repositories, a huge community, a popular free meetings service, several commercial options, and now even a Communications Platform as a Service (CPaaS) with 8×8’s Jitsi as a Service (JaaS). The team, along with the larger open source community, has added a lot and deprecated relatively little over the years. The good news with that approach is that Jitsi gives you a tremendous number of choices. However, the bad side of having so many choices is navigating all the options to figure out which one to make. That’s what this post aims to help with.
Always eager to share their work, the Jitsi team are frequent webrtcHacks authors and always happy to review the work of other authors. They asked for my help introducing their new JaaS service. I agreed to put together this sponsored post so long as I could help make some sense of the large Jitsi ecosystem of projects first and position JaaS and 8×8’s other commercial services aimed at the developer community as part of that.
I thought I was familiar with Jitsi, but reducing all of Jitsi down into something that could be read in 10-15 minutes was harder than I expected. The project is very active and is continuing to evolve so there is plenty more to learn. The post starts with some background on Jitsi and some starting considerations. I then take a deeper review of the 3 main infrastructure alternatives you can start with, including a step-by-step self-install guide. Finally, I finish with a review of the major developer options for using Jitsi as part of your app. This post won’t tell you everything you need to know about Jitsi, but I do expect it will help put you in the right direction. Let me know how well it does in that regard in the comments!
Contents
- About Jitsi
- Jitsi Meet Infrastructure Options
- Public service – meet.jit.si
- Self-installing your own server
- Commercial Service – 8×8.vc & JaaS
- Development Options
- Where to learn more
About Jitsi
Why is the Jitsi project so popular?
Within WebRTC, Jitsi continues to be one of the most popular WebRTC projects. There are a few drivers behind this popularity:
- It has a lot of features. There are a lot of parts to Jitsi (which we will get to), but the culmination of these pieces is a full-featured meetings application that aims to remain competitive with major meetings applications like Zoom, Google Meet, etc. with all the bells and whistles
- It is 100% open-source – perhaps excepting some deployment scripts, everything you see on meet.jit.si, is fully open-sourced somewhere in github.com/jitsi without any proprietary modules or their own closed dependencies
- It works on many platforms – support for all major browsers; native desktop apps for Windows, macOS, and Linux; native mobile support for iOS and Android; even some Apple watchOS support
- It includes many development API’s and SDKs – with multiple levels of JavaScript APIs (which we will cover), an Electron option, React and React Native SDKs, various Android and iOS SDK options, and even watchOS support, developers can modify the standard Jitsi Meet app and launch their own modified apps without needing to fully fork and modify lower-level components (which some still do)
- It has an active community – beyond the many active contributors on github.com/jitsi, the project also has an active community board for questions and help over at community.jitsi.org
- It’s easy to see its features in a production environment – anyone can try the Jitsi Meet app at any time at meet.jit.si completely free.
- It’s used by paying customers – Jitsi’s custodian, 8×8, uses Jitsi with its customers, many of which are critically-minded enterprises, so they have an ongoing economic incentive to keep it maintained, secure, and feature-competitive.
What is Jitsi Used for?
As you might have inferred from the previous section, Jitsi is a big and complex project that serves many use cases. Some of these include:
- Casual online video chat tool for a sysadmin novice
- Secure, self-hosted video meetings platform for a security expert
- Branded service for a telehealth provider
- Enterprise IT-sponsored, customized video conferencing platform for internal collaboration
- Commercial communications platform for a screen sharing service
- Open source Selective Forwarding Unit (SFU) for a video conferencing provider
Jitsi Meet Architecture
Jitsi Meet has a complex architecture that evolved for various needs over a decade. At its core are infrastructure components built around the Jitsi Videobridge, an open-source Selective Forwarding Unit (SFU) – the most popular WebRTC media server architecture.
Jitsi Meet is very web-oriented. All of its core clients are JavaScript based with React Native used to power iOS and Android. The Jitsi Meet web layer includes a wide variety of features designed to be competitive with modern video meeting systems. The iFrame API and React SDKs are built on top of this.
So many choices – how do I choose?
Jitsi is great because it has so many options, but sorting through these options can be overwhelming. This section will cover some of the major considerations you should make before you start. You should leave here with some idea of what sections of this guide you want to read next.
Do you need your own server infrastructure?
Jitsi lets you set up your own server(s) so you have complete control of the service, but do you really need that? If you are a start-up building your own video communications service and your investors expect you to “control your own stack”, then you’ll need to set up servers. If you are privacy-sensitive and want fewer entities between you and your video service, you should set up a server.
If you’re not comfortable navigating a Linux command line and editing configuration files but still really need control over your own server, then you can hire someone to set up the server for you. Just make sure it is someone you trust if you are security-sensitive.
Do you need a Service Level Agreement (SLA)?
Open source projects generally don’t come with any guarantees. Jitsi Meet’s Apache 2.0 license is similar in this regard, but Jitsi is also the free meet.jit.si service anyone can use. What is less obvious, but very valuable to developers, is most of the Jitsi Meet API’s can be used with this free service, subject to their terms and conditions.
However, it is important to keep in mind meet.jit.si is essentially a stable beta service. I am not aware of any major outages with the service, but there are no guarantees about the uptime. If you need uptime guarantees or will exceed the public terms and conditions, then you can either deploy Jitsi Meet yourself (/hire someone to do that for you) or you can pay 8×8 for an enterprise contract that includes an SLA and access to their support services.
How much of the Jitsi Meet front-end do you want to keep?
Jitsi Meet’s comprehensive front-end app is a unique offering among other WebRTC projects. Jitsi Meet includes configuration files that let you adjust many features and control the options that are exposed. If you want to make minor changes, editing these config files is easy without any programming knowledge required.
If you have an existing webpage or are willing to make one, you programmatically interact with the Jitsi Meet front-end via client-side JavaScript using the Jitsi Meet iFrame API. That API lets you cut&paste some code into your CMS or provide. If you want to get into coding, that API also offers more advanced controls with a set of different functions, user control access, and events. The Jitsi Meet React SDK offers something similar, just within the React JavaScript Framework.
If you don’t like the Jitsi Meet UI construct at all and want to make something different, Jitsi Meet also has a lower-level, client-side JavaScript API you can use called lib-jitsi-meet. This API is more akin to what many WebRTC Communications Platform as a Service (CPaaS) video API providers offer, with the ability to initiate calls, publish media, and view other callers – but it is up to you as the developer to connect these things to the DOM and create a user interface for them. This is significantly more development effort.
Lastly, if you don’t like lib-jitsi-meet, you could also work directly with various pieces of the Jitsi infrastructure (notably the Jitsi Videobridge). This requires a deeper level of expertise in WebRTC and the Jitsi architecture. If you are reading this guide then odds are this is not a good option for you.
Where to Start Summary
The remaining sections will go into more detail, but the below table gives a high-level starting guide.
Primary motivation | Free, Freemium, and Open Source | Commercially supported options |
---|---|---|
Just need a Meetings app | meet.jit.si | 8×8.vc |
Have end-to-end control of the meetings infrastructure | Self-install | N/A |
Embed the front-end in my app/page | iFrame API or React SDK | JaaS with the iFrame API or React SDK |
Use the Jitsi back-end and write my own front-end | lib-jitsi-meet | JaaS with lib-jitsi-meet |
Note: 8×8 is planning to launch a hosted components service that would let self-installers use some 8×8-hosted elements on their own installs. webrtcHacks did an early evaluation of this service, but it was not publicly available as of the time of this writing so is not included in this review.
Jitsi Meet Infrastructure Options
Jitsi Meet’s infrastructure comes in 3 flavors:
- a free service – meet.jit.si,
- a commercial service – 8×8.vc and Jitsi as a Service (JaaS), and
- a self-installed service you need to set up and run yourself.
Public service – meet.jit.si
The easiest way to get started with Jitsi is to just use their public service – meet.jit.si. This is a full-featured version of Jitsi. This is not promoted or encouraged by the Jitsi team, but if you want to see the newest, potentially unstable features, you can try https://beta.meet.jit.si/. If you aren’t familiar with their features and you made it this far into this post, then I recommend just going there and poking through the menus to see everything that is available.
It is totally free – 8×8 picks up the bill for all the servers, bandwidth, telephone network connectivity, and the team that maintains it. Why do they do this? If you go there you’ll notice 8×8 uses it as a freemium offer to get you to purchase their commercial services. meet.jit.si also acts as a testing ground for new features before they make their way into commercial products.
Note meet.jit.si does not include the following features:
- Dial-out to a participant via telephone or SIP – this could be abused too easily for SPAM phone calls
- Etherpad server – for collaborative note-taking, but you could point to your own if you apply a custom configuration
- User authentication or even the concept of user accounts
- Customized branding
Terms of Service
As hinted above, as a free service, what you see is what you get with no support or guarantees of uptime. From the Terms of Service:
The Service is provided as-is and without support, and 8×8 makes no commitment or guarantee – and shall have no obligation – relating to any availability/unavailability, uptime/downtime, performance, reliability, functionality, features, or other operation/inoperation of the Service
…
8×8 may – in its sole discretion, at any time, with or without notice, and without any obligation or liability to You or any other party – suspend, terminate, limit, change, modify, downgrade, and/or update the Service (in whole or in part), including without limitation any feature, functionality, Integration or component thereof.
Meet.jit.si’s terms also prohibit you from modifying their branding:
If you are integrating the Service with another service, product, or application for third-party users, or otherwise providing it to or making it available to third-party users for commercial purposes, you shall allow such Branding to be viewed and interacted with by such third-party users for a period of at least 15 seconds from when first presented, and you shall not otherwise remove, obscure, modify, or alter any such Branding.
The terms also restrict the number of endpoints you can have:
The Service is intended for reasonable use at commercially acceptable volumes. As such, Your Use of the Service at no cost is limited to a maximum aggregate total of 25 Active End Points per calendar month (“Monthly Active End Points”) across all of Your accounts.
These terms effectively limit you from offering your own service based on meet.jit.si.
Self-installing your own server
Jitsi makes installing your own Jitsi Meet server relatively easy for such a complex piece of software. They have both Debian package and Docker package installation options. If you are comfortable with Docker, then that is a great route, just note that it does not include a coturn setup like the Debian package install does. In this scenario, TURN should only be needed in unusual scenarios, so that shouldn’t impact many users. For this review, I will focus on the Debian install. I find it slightly easier to navigate.
Note you could also try to build Jitsi Meet from the source code and manually install the dependencies, but there is not much point to that unless you are modifying the project code.
There are many guides out there, including the Jitsi Meet handbook instructions. As part of my review for this post, here is what I did.
Find a cloud provider
First, you need to have a Linux server somewhere. Several cloud providers have images or app packages specifically for Jitsi Meet. I looked at Linode’s Marketplace Jitsi install, but ended up using Digital Ocean’s How To Guide since I already had my DNS setup there.
Make sure to check any Jitsi Marketplace Applications
Before you begin, it is important to check out the details. In this case, the Digital Ocean package supports version 2.0.6726
from December 10, 2021. Is this a recent version? Does it have any major issues? The easiest way to check is to look up the package in the releases list in the Jitsi Meet repo. This is currently 4 releases behind. Is that ok? For production applications, I generally do not run the latest release right away unless it has a specific feature or fix I need. You should also look through the changelog to make sure the newer releases do not contain something you need right away. In this case, I was fine with 2.0.6726
. It is generally easy to update later anyway.
I liked how the DigitalOcean install included fail2ban. Make sure you consider the security implications of hosting a server open before you get started.
Setup the Server
Next, you need to figure out what size server you need. Digital Ocean says upfront:
It is recommended to run this image on a CPU-Optimized droplet with at least 4GB of RAM or higher.
I ended up choosing this image to meet the minimal requirements:
I am not expecting any significant load on my server. I have not had issues with the 4GB / 2 CPU option for hosting a handful of participants.
I already had an SSH key loaded on DigitalOcean for passwordless login.
DNS setup
Generally, you will want an easy-to-access URL like meet.yourdomain.com
. Next, I went to my domain provider and edited the DNS records to add an A and AAAA record to forward that traffic to the DigitalOcean IP addresses I just created:
Software Setup
From there I just had to ssh [email protected]
. The login instructed to type bash complete-jitsi-setup.sh
to finish the install.
When prompted, enter your hostname – i.e. meet.myserver.com
.
Then you’ll be prompted about Let’s Encrypt. Unless you have a certificate you are already using, select the self-signed certificate option:
After that, make note of the certificate file locations if you think you’ll need them later.
See if it worked
Now let’s see if it worked. Go to meet.mydomain.com
and you should see something like:
Start a meeting and copy that URL to another tab/browser and you should see:
Configuring a Jitsi Meet password
This isn’t required, but I prefer to set a password so no one can start a meeting without a user account. Instructions for doing that are here: https://jitsi.github.io/handbook/docs/devops-guide/secure-domain
That was easy
From start to finish this all took me 1 hour and 22 minutes, a good part of which was time taking notes.
Customizing things
Once you have the basic Jitsi Meet setup, there are a few ways you can quickly make modifications.
Change the config files
Jitsi Meet comes with a couple of configuration files you can edit. The most important is the config.js file that you can find at /etc/jitsi/meet/[your-domain]-config.js
in the Debian installation. This config file is well documented. It’s a ~1400-line file with many options for adding features, configuration options, and adjusting the GUI. Get a preview of that file here.
The other config file is interface-config.js
which, in the Debian install, is located in /var/share/jitsi-meet/interface_config
. This file is focused on adjusting the UI controls. This is actually deprecated with most of the values moving to config.js with most of them there already.
URL parameters
Want to test a new feature quickly? All the config.js
options are available as URL parameters. Here is an example:
This URL sets:
- No pre-join screen
- No video (video muted)
- the toolbar to only show the microphone mute and hangup buttons
URL parameters are a quick way to test new features and provide a customized experience for a subset of users without modifying the config files for everyone. Note the iFrame API also lets you load config overrides.
Edit the HTML files
It’s your setup, so one other thing you can do is edit the actual Jitsi Meet HTML and CSS files to make customizations. In the Debian install, those files are located in /usr/share/jitsi-meet/
. I gave a good example of how I used this previously on webrtcHacks when I made a local-recording hack here: https://webrtchacks.com/jitsi-recording-getdisplaymedia-audio/#h.33plzkoh6zd8
Getting more complicated with extra features
The instructions above will get you going with Jitsi, but it is missing several key capabilities available in the Jitsi platform:
- Redundancy – if your server goes down, there is no backup
- Scalability – your capacity will be limited to what your server can handle – 10’s to maybe a couple hundred users depending on what server you choose – depending on the scale you need, you might want to setup cascaded Jitsi Videobridges with Octo
- Dial-in and Dial-out to the telephone network – for that you will need to setup Jigasi
- Transcription for real-time captions – for that you will need to setup Jigasi
- Server-side recording and RTMP streaming – for that you will need to setup Jibri
These elements require separate Debian installs on the same or a different machine. The Docker install includes Jibri and Jigasi. You will want to make sure you have a larger server to handle these elements if running on the same machine. Note a single Jibri instance only works with one conference at a time, so a same-machine setup won’t work with multiple simultaneous conferences.
If you want to handle higher volumes, things can get complicated quickly. If you have 10 conferences you want to record or broadcast, you’ll need 10 Jibri’s. The 8×8 and meet.jit.si infrastructure run Jigasi and Jibri on separate machines with their own auto-scaling for higher better performance and redundancy. Of course, you can replicate that too, but that requires a much more involved configuration of prosody along with management of all those extra servers.
SIP / PSTN Gateway
Jigasi provides SIP gateway for Public Switched Telephone Network (PSTN) calling and transcription functionality. If you want to enable dial-in / dial-out functionality, you will need to have a PBX device or CPaaS with a SIP interface. You’ll also need to set up an HTTP endpoint for a conference mapper service and another that lists the dial-in phone numbers. If I am starting from scratch without a PBX already, it takes me several hours to mimic how meet.jit.si has their dial-in option configured. See a reference project I made for this on the Community Forum here.
Transcription / Captions
Transcription requires setting up Google Cloud Speech-to-Text or the open-source Vosk Speech to Text server. Vosk is free, but you need to manage the server. Google generally gives much better transcription accuracy, but you’ll pay for each 15-second interval of use.
Recording and Streaming
Jibri joins your conference as a silent participant. It uses a headless Chrome instance and the popular FFmpeg AV tool to save that to disk or broadcast it over RTMP. This process is resource-intensive. As mentioned above, a single Jibri can only handle one recording at a time.
Commercial Service – 8×8.vc & JaaS
8×8 also offers a commercial deployment of Jitsi at 8×8.vc. This is geared at businesses. As of this writing, 8×8 Meet Pro costs all of $1/user/month.
It does everything meet.jit.si does with some additions:
- Dedicated 8×8.vc URLs
- An admin console for management
- Team management
- Build-in branding customization
- Web interface for Spaces – the Jitsi system for physical rooms (called Spot in the repo)
- Analytics from callstats.io (which 8×8 acquired)
Importantly, the terms are slightly different. They offer an “8×8 DATA PROTECTION COMMITMENT”. There is no SLA, but you can get one from 8×8 if you negotiate an enterprise agreement with 8×8 or upgrade to one of their phone plans.
The 8×8.vc infrastructure is separate from the meet.jit.si and is used in all of 8×8’s commercial offers that use Jitsi, including those aimed at higher-end enterprises with serious SLA’s. You can check on service stats at status.8×8.com. They do not publish historical uptime stats but they manage this network to be extremely stable. 8×8 potentially needs to compensate customers for any outages. Typically new features are run on meet.jit.si before they make it to 8×8.vc, ensuring there are fewer bugs.
Jitsi as a Service (JaaS)
As we will cover in the next section, there are many developer interfaces included with Jitsi that you can access via self-install and even for free on meet.jit.si. The commercial alternative on the 8×8.vc network is called Jitsi as a Service or JaaS. This is the 8×8 Communications Platform as a Service (CPaaS) offer for developers who want to build on top of their system.
JaaS Pricing
As of this writing, pricing starts at $0.33/user/month with a committed number of users. A user is one endpoint that accesses the system. The first 25 monthly active users (MAU) are free (the same number as meet.jit.si). Dial-out, SIP, transcription, recording, and streaming each have their own charges. Dial-in functionality consumes 2 MAU and dial-out takes one, plus the fee. It is $1/MAU if you exceed the committed number.
Note: JaaS does not include a storage option for your recordings – you’ll need to transfer and store those yourself.
Development Options
Jitsi includes a number of development options. Which one you use comes down to one main choice:
Do you want to use the Jitsi Meet UI framework or not?
If you generally like Jitsi Meet’s features and its concepts around managing participants but want to programmatically control what features are exposed or alter when or how features are invoked, then you should use the Jitsi Meet UI framework. The primary choice there is the iFrame API (i.e. JitsiMeetExternalAPI
). If you are a React developer or working on a react project, then there is a roughly equivalent React SDK. If you want to build your own iOS and Android applications, there are Android and iOS SDKs based on React Native.
If you want something lower-level, largely focused on creating conferences and sending and receiving streams from that conference, then you should use the lib-jitsi-meet API.
The sections below will compare the iFrame API to lib-jitsi-meet.
Jitsi Meet iFrame API
Jitsi Meet has an “Embed Meeting” feature that outputs some HTML with an iFrame of that meeting – THIS IS NOT the iFrame API.
First, you need to load the external_api
.
1 |
<script src='https://meet.jit.si/external_api.js'></script> |
Change meet.jit.si
with your own domain if you are self-hosting or https://8x8.vc/external_api.js
if you are using the 8×8 network.
Then the iFrame API looks like this.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
<script> const options = { roomName: “webrtcHacksExample”, configOverwrite: { toolbarConfig: { alwaysVisible: true, }, prejoinConfig: { enabled: false } }, interfaceConfigOverwrite: { APP_NAME: 'Jitsi Meet (Customized)', AUDIO_LEVEL_PRIMARY_COLOR: 'rgba(230,60,60,0.5)', AUDIO_LEVEL_SECONDARY_COLOR: 'rgba(230,60,60,0.2)', DEFAULT_BACKGROUND: '#4b1616', FILM_STRIP_MAX_HEIGHT: 240, VERTICAL_FILMSTRIP: false, }, userInfo: { displayName: `user${Math.floor((Math.random()*100)+1)}` }, height: 700, parentNode: document.querySelector("#meet"); }; const api = new JitsiMeetExternalAPI(“meet.jit.si”, options); </script> |
The options
object lets you set the room name, credentials, iFrame size, participant, and available media device info, and where in your DOM where you want to insert the iFrame. In addition, you can set overrides for the meet config.js and interface_config.js, See those links for the long list of options.
In addition, the JitsiMeetExternalAPI
lets you setup event listeners and invoke commands on behalf of the user. For example, the following code lets you detect when the user changes their audio mute status and sends a message in the chat:
1 2 3 4 5 |
api.addEventListener('audioMuteStatusChanged', obj=>{ const mutedStatus = obj.muted ? "muted" : "unmuted"; console.log(`webrtcH4cKs$ ${mutedStatus}`); api.executeCommand('sendChatMessage', `I ${mutedStatus}`); }); |
iFrame API with Jitsi-as-a-Service (JaaS)
If you use JaaS, this will look similar, except you must include App ID in the first part of the roomName
and a JavaScript Web Token (JWT):
1 2 3 4 5 6 7 8 9 |
document.querySelector('button#iframe').onclick = () => { console.log("starting"); const options = { roomName: `vpaas-magic-cookie-getthiskeyfromjaas/webrtchacks`, jwt: yourJWT, height: 700, parentNode: targetNode }; cont api = new JitsiMeetExternalAPI(domain, options); |
You will need a server-side function to generate a JWT for each user you want to authenticate. 8×8 includes examples on how to do this for all the popular web server languages here: https://github.com/8×8/jaas_demo/tree/main/jaas-jwt-samples. Setting this up only took me a couple of minutes – just be careful to use the right fields. The appId
and sub
are the same. The kid
includes the appId
– i.e. vpaas-magic-cookie-some20charGUID
with a /
and a shorter 5-digit id.
The JWT can also be used to control what resources the user can access to limit any unintended charges. See full details on the JWT setup here.
It is up to the developer to incorporate this logic and pass the JWT to the user. You can also generate these tokens from the JaaS web console for quick testing.
lib-jitsi-meet
The externalAPI loads JitsiMeet into an iFrame. It gives some control on how the contents look and lets you programmatically interact on behalf of the user, but it requires that iFrame and inherits Jitsi’s UI paradigms. lib-jitsi-meet is lower-level and makes zero assumptions about the UI. Its core objects include:
JitsiConnection
– this class is your connection to the Jitsi Videobridge (JVB) where you need to authenticate and create or join a conferenceJitsiConference
– this object controls how the user interacts with a conferenceJitsiTrack
– the object type lets you control the media streams sent to or received from the conference
Unlike the iFrame ExternalAPI, you can choose how you want to handle a remote participant, including ignoring them or just not rendering their media. It’s up to you to create video/audio DOM elements and handle them.
You will need to write a lot more code with lib-jitsi-meet, since you have to handle the interaction of between Jitsi Meet’s signaling, the media streams, and the UI. Here is a very basic example:
See the Pen
lib-jitsi-meet on meet.jit.si by Chad (@chadwallacehart)
on CodePen.
Where to learn more
I included most of these links above, but here are some again for you convenience (and mine):
- Try the service yourself – meet.jit.si or 8×8.vc
- Jitsi as a Service (JaaS) – jaas.8×8.vc
- The Jitsi Meet Handbook – jitsi.github.io/handbook
- Jitsi Community Forum – community.jitsi.org – this the best place to go for questions that aren’t covered in the documentation
- The main Jitsi Meet repo – github.com/jitsi/jitsi-meet
- Main website: jitsi.org
{“author”: “chad hart“}
Muhannad says
Hi, I am not sure if you faced this issue but I have been struggling with it for a couple of days now. I used both 8×8 service and my own installation but I keep facing the issue. which is:
I am using the iFrame to embed a video call inside my website, the application is working fine on Firefox and safari but not in Chrome and Edge. it complains about CORS. this is a link to stackoverflow https://stackoverflow.com/questions/73118947/jitsi-iframe-cross-domain-issue
I am not sure where to put the header override for the requests to add the CORS in the response header. in my instance I tried it in the web part of the Jitsi but with no success . can you please help me, If you have faced the issue or if I am missing something around the issue
Chad Hart says
I would take this up on community.jitsi.org if you haven’t already.