OpenChamber VS Code Extension

OpenCode AI coding agent, right inside your editor. No tab-switching, no context loss.

Like the extension? There's also a desktop app and web version with even more features.
What you get
- Chat beside your code — responsive layout that adapts to narrow and wide panels
- Run on several models — send one prompt to several models at once, compare the answers side by side, keep the best or fuse them
- Right-click actions — add context, explain selections, and improve code in-place
- Click-to-open — file paths in tool output open directly in your editor; edit-style results land in a focused diff view
- Session editor panel — keep chat sessions open alongside files
- Theme-aware — adapts to your VS Code light, dark, and high-contrast themes
Plus everything from the shared OpenChamber UI: branchable timeline, smart tool UIs, voice mode, Git workflows, and more.
Commands
With no folder open, new sessions start in Chats. Each chat has its own directory
under ~/.config/openchamber/chats. Open a workspace folder to use project sessions.
| Command |
Description |
OpenChamber: Focus Chat |
Focus the chat panel |
OpenChamber: New Session |
Start a new chat session |
OpenChamber: Open Sidebar |
Open the OpenChamber sidebar |
OpenChamber: Run on Several Models |
Open a new tab set up to run one prompt on several models |
OpenChamber: Open Session in Editor |
Open current or new session in an editor tab |
OpenChamber: Settings |
Open Settings in an editor tab. Repeat invocations reveal the same tab and leave the chat sidebar unchanged. |
OpenChamber: Restart API Connection |
Restart the OpenCode API process |
OpenChamber: Show OpenCode Status |
Debug info for development or bug reports |
OpenChamber: Generate Commit Message |
Fill VS Code's Source Control commit box from staged changes, or unstaged if nothing is staged |
Select code in the editor, right-click, and find the OpenChamber submenu:
| Action |
Description |
| Add to Context |
Attach selection to your next prompt |
| Add Comment |
Open a comment thread on the selected lines. The comment stays anchored in the editor and goes out with your next message as a context card. The gutter + does the same once the extension is active |
| Explain |
Ask the agent to explain the selected code |
| Improve Code |
Ask the agent to improve the selection in-place |
Configuration
| Setting |
Default |
Description |
openchamber.apiUrl |
(empty) |
URL of an external OpenCode API server. Leave empty to auto-start a local instance. Authenticates with OPENCODE_PASSWORD (or the legacy OPENCODE_SERVER_PASSWORD); when both are unset and the URL points at OpenCode's background service (opencode service start), the service's own password is used. |
openchamber.opencodeBinary |
(empty) |
Absolute path to the opencode CLI binary. Useful when PATH lookup fails. Requires window reload to apply. |
Both settings belong to one machine. In a Remote-SSH window the extension ignores the values from your local User settings: set them in the Remote or Workspace tab of the Settings editor. With no value on the server, the extension finds opencode there on its own.
npm metadata and OpenCode version checks use the registry from the extension host environment or the user's .npmrc, including scoped registries and authentication.
Requirements
- OpenCode CLI installed and available in PATH (or set
OPENCODE_BINARY env var)
- VS Code 1.85+
Development
bun install
bun run vscode:dev
bun run vscode:dev now starts watchers + opens an Extension Development Host automatically. Webview UI changes use Vite HMR automatically.
Optional overrides:
OPENCHAMBER_VSCODE_BIN=cursor bun run vscode:dev
OPENCHAMBER_VSCODE_DEV_WORKSPACE=/path/to/workspace bun run vscode:dev
bun run vscode:dev /path/to/workspace
OPENCHAMBER_VSCODE_REMOTE_DEBUGGING_PORT=9334 bun run vscode:dev runs the host as its own VS Code instance in a throwaway profile, with Chrome DevTools Protocol on that port, even while another VS Code is open. The OpenChamber webview is the vscode-webview:// iframe target; its document is that target's inner iframe. Stopping the script closes the instance and removes the profile.
To package manually:
bun run --cwd packages/vscode build
cd packages/vscode && bunx vsce package --no-dependencies
Install locally: code --install-extension packages/vscode/openchamber-*.vsix
License
MIT