We're sorry but this app doesn't work properly without JavaScript enabled. Please enable it to continue.

This lesson's interactive features are locked, please to keep using them

GUI Clients

OpenCode isn't just a TUI. The agent itself is a server running in the background on your machine, and the TUI is just a client that connects to it. And OpenCode ships three types of clients:

  • The TUI, which is the opencode command you already know.
  • The Web UI, which runs in your browser.
  • The Desktop App, which is a native app for macOS, Windows, and Linux.

The Web UI

To use OpenCode in the browser, just generate a pairing link with the pair command:

opencode pair

This starts the shared background service if it wasn't already running, and gives you a link to open:

It can be configured to include a QR code in case you want to open it on your phone... more on that later.

You can stop the background server with opencode service stop, but I recommend just leaving it on even when you're not actively using OpenCode – it's lightweight and means your next session will start instantly.

The Desktop App

OpenCode Desktop is a native app for Linux, macOS, and Windows. We won't be using it in this course, but it's good to know it exists.

It renders the same interface as the web UI, and it connects to the same background service. It allows for the things a browser tab isn't allowed to do:

  • Native file and folder pickers
  • Pasting screenshots straight from the clipboard
  • Dragging in a file so the agent gets its real path
  • "Reveal in Finder" (or the equivalent on Windows or Linux) and one-click open in VS Code, Cursor, Zed, or Ghostty
  • Auto-updates, instead of re-running the install script

Picking a Client

Client Good at Tradeoff
TUI (opencode) Scripting, automation, SSH, speed Weakest for large diffs or anything overly visual
Web UI (opencode pair) Reachable from your phone, comfortable review UI The browser can't touch your filesystem natively
Desktop Native file handling and editor handoff, auto-updates Doesn't run on a phone or in a terminal

I use all 3: TUI for code-heavy work. Web for mobile. Desktop (very occasionally) for tasks that require native file handling or lots of images.

Assignment

Use the Web UI to add a SlopLang example that prints the result of (1 + 2) * 3 (notice we added some parentheses!).

In the web UI, tell OpenCode to run and submit the CLI tests from the project root.