NELKINDA SOFTWARE CRAFT

Microsoft Teams on Linux

Microsoft seems not to want it, but you can actually run Microsoft Teams audio and video calls on Linux, in a browser. Just change the User-Agent identification to Edge on Windows, and it will work.

Author:
Christian Hujer, Software Crafter and CEO / CTO of Nelkinda Software Craft Private Limited
First Published:
by NNelkinda Software Craft Private Limited
Last Modified:
by Christian Hujer
Approximate reading time:
Figure -1: Microsoft Teams video call in Chromium on Linux (Kubuntu 18.04.1 LTS) (Full resolution: 3840×2160)

In one of my current projects, the client decided to go for Microsoft Office 365, Microsoft Azure, and Microsoft Azure DevOps as the primary infrastructure platforms. For me as a Linux user, this spells potential trouble: will everything work? Most of the things actually work just fine in the browser. Just one application refused to do some of its work. That is Microsoft Teams. Texting in Microsoft Teams works just fine. But Microsoft Teams refuses to do audio or video calls on Linux. There's an easy way how to make Microsoft Teams do audio and video calls even on Linux. That is to change the User-Agent string used by the browser to pretend that it is Edge on Windows. And that way leaves us wonder what Microsoft are thinking and doing.

1 The Quick Way

This is the quick description for versatile users.

  1. Start Google Chromium or Google Chrome.
  2. Open Microsoft Teams.
  3. Open the Developer Tools.
  4. Select the Network tab.
  5. Ensure that the Console drawer is open (⋮ in the top right corner).
  6. Open Network conditions (⋮ on the left of the Console drawer).
  7. At User agent, disable "Select automatically".
  8. Choose the User-Agent "Edge — Windows".
  9. Keep the developer tools open.
  10. Reload Teams.

Now you can enjoy audio and video calls in Microsoft Teams on Linux! (Just screen sharing still doesn't work.)

On request, I may come up with a detailed description with screenshots or maybe even a YouTube video.

2 Microsoft, WTF?

Hello, Microsoft? I didn't do anything quirky to get this running. All I did was to change the User-Agent [Wikipedia:User Agent] identification. This identification can be queried by JavaScript or the server. This means that Microsoft has actively, consciously, written some piece of code which checks the User-Agent and refuses to work if the User-Agent is on Linux. There is no technical reason to do so. I didn't program anything to get this working. This was working already, and there is a piece of code written by Microsoft that stops it from working.

What are the reasons? Given that I'm in "this business" since 1984 and I've seen a lot of shit from Microsoft, I may have become quite sarcastic. But I see only two possible reasons for this. Either, Microsoft is stupid. Or, despite its claims of having changed their strategy to like Linux, parts of Microsoft still actively sabotage Linux. Whatever it is, it doesn't look good. And it makes me, once again, feel angry about Microsoft and its destructive behavior.

If you ever wondered why some people hate Microsoft so much, it's stuff like this!

3 Limitations

Note that there is another glitch when you use Microsoft Teams on Linux in Chrome and set the User-Agent to Edge on Windows. In that case, loading message histories is broken. Currently, in order to use Microsoft Teams on Linux in Chrome, you need two tabs.

4 Credits

I didn't figure this out myself. This solution was suggested by Rene Greuel at [UserVoice:MicrosoftTeams:LinuxClient]. Thanks a lot to Rene Greuel for figuring this out and sharing this with others.

Also thanks to Sagar Doddamani for being my guinea pig for testing audio and video calls and for agreeing to have a screenshot taken for this blog article.