Move your workplace to real-time IM on ejabberd — a quick overview.

  • Your business becomes very dependent on an external service. Any downtime means your office goes silent (ekhm, MS Teams).
  • Your business inherits all the vulnerabilities of the external service. Your office staff is open to hacking (ekhm, Zoom…).
  • Your business costs aren’t scalable. External services charge by the seat, so your bill becomes significant overnight and grows when your office grows.

Install ejabberd real-time IM server

You can set up your ejabberd real-time IM platform on a VPS server. Or on a server inside your company VPN. You can even install it on a laptop. Just make sure it’s connected to the Web using a static IP. And your Internet router forwards the necessary ports, so the laptop is reachable from the outside world.

wget -O ejabberd_20.03.debapt install ./ejabberd_20.03.deb
nano /opt/ejabberd/conf/ejabberd.yml
- ""
- ""
contact: ""
/etc/init.d/ejabberd start
cd /opt/ejabberd-20.03/bin 
./ejabberdctl register admin ********
> User successfully registered
- "/opt/ejabberd/conf/fullchain.pem"
- "/opt/ejabberd/conf/privkey.pem"

Create chat users in ejabberd real-time IM server

In the web admin console, using the side menu, go to Virtual Hosts and click on your domain. Then from the side menu select Users. You can add each user by typing in the username and password. All users appear on the list below.

Create shared contact lists in ejabberd real-time IM server

Once all users have their accounts, it would be nice if just after logging into their favorite XMPP client (I’ll suggest some apps later on) they could see all their colleagues in the contact list. For this, we need to create a shared contact list (shared roster).

Create rooms for IM group chats

Now that all your users can chat with each other, it’s time to create chat rooms (also known as group chats or Multi-User Chats). It’s quite simple, really. You do it right in your XMPP client. Most of them have it under the plus sign, where you can choose to start a new chat with a specific person, join a chat room, or create one.

cd /opt/ejabberd-20.03/bin ./ejabberdctl create_room open # creates a public chat room

./ejabberdctl change_room_option open persistent true # makes chat room persistent
./ejabberdctl change_room_option open title "Open Discussion" # assigns a room title

Install IM chat apps (XMPP clients)

There are many different IM chat apps (XMPP clients), for many different platforms: macOS, Windows, Linux, iOS, Android… You can find a complete list here.



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store