Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Teams CompanionNew to Visual Studio Code? Get it now.
Teams Companion

Teams Companion

Preview

Ruben Jongejan

|
1 install
| (0) | Free
Read Microsoft Teams chats, find conversations, and reply from a VS Code editor tab.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Teams Companion

Read a Microsoft Teams conversation beside your code. Find a chat in the sidebar, open it in an editor tab, and keep your place while new messages arrive. Each tab stays tied to the account that opened it.

Teams Companion in VS Code, with a searchable chat list and an open conversation

  • Find a conversation. Search loaded chats, filter for groups or unread messages, and move through the results with the arrow keys.
  • Catch up. Read messages grouped by sender and date. Load older history or jump to the newest reply.
  • Reply deliberately. Enable replies on a writable profile, draft in the editor, and send with Cmd+Enter on macOS or Ctrl+Enter on Windows and Linux.

Teams Companion is an independent desktop extension powered by Teams CLI. Microsoft Graph supports work or school accounts. The experimental desktop connection also supports personal accounts and reads the history available in the local Teams cache.

Get started

  1. In desktop VS Code, choose Install Pre-Release Version for Teams Companion by rvben. For a downloaded VSIX, choose Extensions > Install from VSIX. GitHub releases include a SHA-256 checksum for the download.
  2. Open Teams in the activity bar. If the CLI is missing, click Choose a CLI. Select an existing executable or choose Download verified CLI to install the version pinned by the extension from the CLI's official GitHub release. The extension checks the archive against the release checksum pinned in the extension before extracting it into extension storage.
  3. In Chats → …, choose Guided Account Setup. A dedicated VS Code terminal runs the CLI’s setup wizard, checks which connections work on this computer, and walks through account choice and sign-in. On success, the extension selects the resulting profile and refreshes Chats.
  4. Open a conversation from the sidebar or use Teams: Find Conversation.

Requires VS Code 1.96 or newer. Choose Download verified CLI for the preview. The installed preview uses its verified download by default. To supply your own compatible CLI, select its executable in Settings. The built-in download supports macOS Intel/Apple Silicon, Windows x64 (including x64 emulation on ARM64), and Linux x64. On other hosts, supply a compatible CLI yourself. The extension does not run in vscode.dev or other browser-only extension hosts.

Choose a connection

Guided Account Setup runs teams init in a dedicated terminal with Teams CLI 0.2.2 or newer. The CLI validates installed browsers, account support, saved sessions and available ports before offering a connection. Choose Personal or Work/school. For a dedicated work or school browser, choose Other connection options and then Live chats for work or school. Select that profile in the extension and choose Sign in to browser chats. If setup is interrupted, run it again to recover the saved setup. Closing the terminal cancels the extension’s wait; it does not discard existing profiles.

On-demand chats open the official Teams web app in a browser dedicated to this profile, read the requested conversation, and close the browser. Use Load chats or refresh for new messages. Choose Live chats to keep the browser open while connected. Both modes accept personal or work or school accounts on macOS, Linux and WSL. Sign in once in the visible Teams window. Connecting may reopen your last conversation and mark it read. Live work or school access in a licensed tenant is still awaiting verification in this preview.

Existing desktop and regular browser profiles need a separate sign-in when switching to the managed preview. Use Guided Account Setup to create the new profile. Teams Companion uses a private pipe for its browser. If you also use the CLI from another terminal, an on-demand profile can serve authenticated chat requests on its loopback port. Start it with teams --profile PROFILE --yes desktop chat-port and list chats with teams --profile PROFILE --yes --via-chat-port chats list. Replies over the port require both a writable profile and the explicit server option --allow-replies.

Native Windows supports Microsoft Graph in this preview. Personal and browser-based work or school connections require the Linux extension host in WSL.

Microsoft Graph uses a work/school account. Graph sign-in offers the CLI’s browser flow and device-code flow. Choose Request channel history only if you need the additional administrator-consented scope. The CLI runs sign-in in a dedicated local terminal. Complete sign-in yourself, then refresh the conversation list. The extension does not handle passwords or store access tokens. Run Teams: Sign In to Graph Profile if sign-in expires.

The extension prefers the local UI extension host. In a Windows window this uses a Windows CLI and Windows profiles. To use a Linux CLI and WSL profiles, install the extension in the WSL distribution and set "remote.extensionKind": { "rvben.teams-companion": ["workspace"] } in your VS Code user settings. Reload the WSL window. Check Teams: Show Connection Diagnostics for the selected CLI path. Visible browser sign-in inside WSL2 requires WSLg or a graphical display. SSH and container windows use local account setup.

Make the sidebar yours

In the Chats … menu, choose Change Sidebar Layout to switch instantly between three layouts. The same choice is available in Settings as teamsCompanion.sidebarLayout.

Layout Conversation rows
Teams Avatars, one-line previews, timestamps and unread indicators.
Compact Smaller avatars and single-line rows for a longer list.
Comfortable Larger avatars and two-line previews with more breathing room.

Light theme showing the chat list and reply composer

Your choice persists across windows. Switching layouts keeps the selected profile, open conversation tabs and drafts intact. Use Search loaded chats, Unread, or Groups to narrow the current list. Load more conversations expands that list; search does not query all Teams history. Arrow keys move between rows; Enter opens a conversation. Refreshing keeps your scroll position.

Avatars use raster photos supplied by the CLI, with initials when a photo is unavailable. The optional desktop photo support reads only avatars already loaded in the selected Teams page; it never downloads remote images or opens another account. Older CLI versions and Graph profiles show initials. Unread indicators appear only when the CLI provides unread state or comparable read/message timestamps. Missing status is not treated as unread. In a browser profile, Teams may mark a conversation read when it opens.

The Chats view refreshes at the configured interval while visible. The native Connection section starts collapsed, with a plug button beside the profile for quick access.

Start a conversation

Click the New Message compose icon in the Chats title bar, or run Teams: New Message. Search by name or full email address, then select the exact person. The picker shows the account/profile and each result’s address or Teams identity. Selecting a person opens or creates a one-to-one conversation in an editor tab; no message is sent until you press Send. Existing conversation tabs are reused.

New conversations require a writable profile and replies enabled. Personal Teams uses Teams’ own live people search and contacts; discoverability settings can limit results. Work/school Graph search requires User.ReadBasic.All; sign in again to grant it. Organization policies can restrict who you can contact. Groups, phone/SMS invitations and off-network email invitations are not supported.

This feature needs a CLI build advertising people search and chats create in its schema. Older CLIs keep reading and replying normally and explain the missing capability when you choose New Message. Chat creation is never retried automatically. An uncertain creation is guarded across windows/restarts; check Teams before explicitly trying again. This guard stores no recipient names, addresses, or message text.

Read and reply

  • Refresh loads the latest available history; Load older messages pages backward. Incoming messages leave your reading position in place and offer a jump to the latest message.
  • Teams: Find Conversation searches the conversations loaded in the sidebar. Load more conversations to expand that set.
  • Replies require both a writable CLI profile and Teams: Enable Replies. The extension starts with replies disabled.
  • By default Ctrl+Enter or Cmd+Enter sends; Enter inserts a line. teamsCompanion.sendOnEnter changes this to Enter, with Shift+Enter for a new line. IME composition and paste never trigger a send.
  • Messages are plain text. Attachments, reactions, mentions, edits, channel threads, and calls are not implemented. Received HTML is converted to text; remote images and message HTML never execute.
  • A submitted message is not proof of delivery. If a send times out, the CLI exits unexpectedly, or Teams reports an uncertain result, replies in that conversation are blocked. Check send status uses the exact client message ID when available. Absence from cached history never proves failure. If no ID is available, check the conversation in Teams. I checked in Teams… requires a confirmation before unlocking replies; review the retained draft carefully to avoid duplicates.

Drafts stay in memory across refreshes and closing/reopening a tab. They are lost when the extension host exits. Message bodies are not written to draft files or logs. A small journal containing operation IDs, timestamps, and optional client message IDs preserves uncertain-send protection across restarts and multiple VS Code windows. Journal filenames hash the profile/config/chat scope. No send is retried automatically.

The CLI section in the Teams sidebar shows the active version and who manages it; hover for its executable path. Teams: Manage CLI lets you select an executable, use the recommended verified download, or turn automatic managed updates on or off.

Turning automatic CLI updates off keeps the version already in use. The CLI section shows the actual executable, including an automatic upgrade when the CLI path setting still names its original download. Previously verified local copies are checked against their saved checksum and validated before reuse.

Copies downloaded by the extension, including older downloads already selected in settings, automatically upgrade to the version tested with the installed extension. This is a pinned version, not an arbitrary latest release, and newer installations are never automatically downgraded. Downloads are checked against SHA-256 hashes embedded in the extension and checked for the expected version and chat protocol on supported hosts before selection. A failed update keeps the current CLI. Switching waits for sends, account setup, and other current work to finish; managed upgrades preserve open conversations, drafts, and send-status guards. You manage updates for executables you select outside extension storage. Choose Use recommended CLI to switch explicitly.

Settings and troubleshooting

Setting Default Purpose
teamsCompanion.cliPath empty Absolute executable path. The preview defaults to the verified download. Machine-scoped, never a workspace command.
teamsCompanion.autoUpdateCli true Upgrade extension-managed CLI copies to the tested version when idle. External installations are preserved.
teamsCompanion.repliesEnabled false Permit replies when the CLI profile allows them.
teamsCompanion.pollIntervalSeconds 30 Refresh interval from 10 to 300 seconds for the visible sidebar and the active conversation in the focused window. Conversation failures increase the time between checks.
teamsCompanion.sidebarLayout teams Choose Teams, Compact, or Comfortable sidebar rows.
teamsCompanion.checkForUpdates false Opt in to a daily check for GitHub downloads on this release channel.
teamsCompanion.sendOnEnter false Send with Enter; Shift+Enter inserts a line.

Run Teams: Show Connection Diagnostics for an output channel containing allowlisted host/backend/error metadata. It excludes message bodies, raw CLI output, account identities, tokens, profile names, and chat IDs. For account or cache issues, open Teams itself and refresh there. The extension shows history under the account selected by the CLI; it cannot independently verify a desktop account's identity. Avoid switching Teams accounts during an active send.

No telemetry is collected. Normal reads and sends go through the chosen CLI backend. Downloads and extension update checks contact GitHub using a generic User-Agent, without Teams account data.

Marketplace installations use VS Code's extension update settings. For manual VSIX installations, Teams: Check for GitHub Release looks for a newer download on the installed extension’s release channel. Enable teamsCompanion.checkForUpdates to receive these notifications automatically at most once a day.

Open Teams opens the appropriate Teams website in your browser. No conversation body or identifier is placed in that URL.

Development

Node.js 22 or newer:

make deps
make check test-all

The UI suite uses Playwright Chromium; install it with npx playwright install chromium, or set CHROME_PATH to an existing Chrome for Testing / headless-shell binary. On macOS, avoid launching system Chrome for automated checks. The extension-host suite downloads and caches an official VS Code test build; set VSCODE_EXECUTABLE to test an existing installation instead. It uses isolated user data and synthetic fixtures, with real writes disabled in the fake CLI. Desktop setup and connection regression tests use an in-memory host and cannot restart Teams. F5 opens a separate Extension Development Host.

The VSIX includes only bundled runtime code, theme stylesheets, the extension and activity-bar icons, this README, changelog, licenses, and manifest. Tests, synthetic data, local research, design documents, and screenshots are excluded. Packaging is local; it does not publish to the Marketplace.

See CONTRIBUTING.md for test and release instructions, SECURITY.md for private vulnerability reports, and GitHub issues for bugs and feature requests. The project is MIT licensed.

Browser lifetime

With Teams CLI 0.2.3 or newer, which supports desktop supervise, browsers started by Teams Companion close after their last extension user exits, including when the extension host crashes. A 15-second grace period lets a reloaded window reclaim its browser. Multiple VS Code windows share the browser safely, and active CLI commands can finish before cleanup. Saved sign-in is retained. Sessions started separately, or by older CLI versions, stay running; explicitly running desktop connect from a terminal also keeps that session running. Native Teams is unaffected.

Enable Teams Companion: Keep Browser Running to preserve newly started browser sessions after exit. You can always use Disconnect browser to close one. With an older CLI, the CLI section explains that an update is needed for automatic cleanup.

The extension uses a small CLI supervisor with a private stdin pipe. Closing the pipe triggers the CLI's verified browser cleanup; no process-name matching or broad process-tree kills are used. A supervisor forcibly killed along with the browser's other processes cannot perform cleanup; desktop recover remains available.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft