Search code examples
microsoft-teams

Open a popup (e.g. native browser) from a Teams desktop client app tab


Is there any way to pop open a browser window from a Teams app tab (desktop client)?

I came across the following link and from my interpretation of the reply it seems it's not possible.

Quoted from link for reference:

Unfortunately it’s not possible to use window.open in Teams tabs. Because we block opening of new windows to arbitrary sites within our Teams Desktop Client (for security reasons) you need to always use microsoftTeams.authentication.authenticate (if you want a popup window) or microsoftTeams.tasks.startTask (if you want an iframe-based dialog) to open a secondary app view.

It's not very clear to me what the microsoftTeams.authentication.authenticate reference above is suggesting.

Alternatively, if not a browser window, can we attempt to open another app installed on the device (e.g. Excel)?

Thanks in advance!


Solution

  • Are you just wanting to launch a new browser entirely? If so, a regular anchor tag, with a target attribute (e.g. ...), will work fine (I'm doing this in a tab myself, and it's working without problem).