

0 / 2 embers
0 / 3000 xp
click for more info
Complete a lesson to start your streak
click for more info
Difficulty: 3
click for more info
Not enough gems
Cost: 6 gems
1: Learn AI Coding
incomplete
2: Chat, Autocomplete, and Agents
incomplete
3: Installing OpenCode
incomplete
4: OpenCode Console
incomplete
5: The Unix Philosophy
incomplete
6: OpenCode Config
incomplete
7: CLI Config
incomplete
8: OpenCode Run
incomplete
9: GUI Clients
incomplete
10: Mobile Usage
incomplete
11: Remote Server
incomplete
Back
ctrl+,
Next
ctrl+.
This lesson's interactive features are locked, please to keep using them
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:
opencode command you already know.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.
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:
| 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.
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.