--- title: "簡介" description: "安裝開源編碼 agent OpenCode:可使用 CLI、桌面應用程式、Web 應用程式或 Docker 映像。接著連接模型供應商即可開始使用。" --- OpenCode 是一個開源編碼 agent。它提供終端機介面、桌面應用程式與 Web 應用程式。 ## CLI npm 套件會透過 postinstall 指令碼選擇適合你平台的原生 `opencode` 二進位檔。上述 Bun 和 pnpm 指令已明確允許執行該指令碼;Vite+ 不需要額外旗標。mise 指令需要 mise 2026.10.9 或更新版本;舊版 mise 會安裝 OpenCode 1。 不支援 Windows 套件管理工具。 請依你的平台下載對應的獨立 CLI 二進位檔。 - **macOS:** [Apple 晶片](https://opencode.ai/update/api/latest/cli/opencode/opencode-darwin-arm64.zip) · [Intel](https://opencode.ai/update/api/latest/cli/opencode/opencode-darwin-x64.zip) · [Intel(baseline)](https://opencode.ai/update/api/latest/cli/opencode/opencode-darwin-x64-baseline.zip) - **Windows:** [ARM64](https://opencode.ai/update/api/latest/cli/opencode/opencode-windows-arm64.zip) · [x64](https://opencode.ai/update/api/latest/cli/opencode/opencode-windows-x64.zip) · [x64(baseline)](https://opencode.ai/update/api/latest/cli/opencode/opencode-windows-x64-baseline.zip) - **Linux(glibc):** [ARM64](https://opencode.ai/update/api/latest/cli/opencode/opencode-linux-arm64.tar.gz) · [x64](https://opencode.ai/update/api/latest/cli/opencode/opencode-linux-x64.tar.gz) · [x64(baseline)](https://opencode.ai/update/api/latest/cli/opencode/opencode-linux-x64-baseline.tar.gz) - **Linux(musl):** [ARM64](https://opencode.ai/update/api/latest/cli/opencode/opencode-linux-arm64-musl.tar.gz) · [x64](https://opencode.ai/update/api/latest/cli/opencode/opencode-linux-x64-musl.tar.gz) · [x64(baseline)](https://opencode.ai/update/api/latest/cli/opencode/opencode-linux-x64-baseline-musl.tar.gz) ## 桌面應用程式 請依你的平台下載最新的 OpenCode Desktop 版本。 - **macOS:** [Apple 晶片](https://opencode.ai/update/api/latest/desktop/opencode/opencode-desktop-mac-arm64.dmg) · [Intel](https://opencode.ai/update/api/latest/desktop/opencode/opencode-desktop-mac-x64.dmg) - **Windows:** [x64](https://opencode.ai/update/api/latest/desktop/opencode/opencode-desktop-win-x64.exe) · [ARM64](https://opencode.ai/update/api/latest/desktop/opencode/opencode-desktop-win-arm64.exe) - **Linux(.deb):** [x64](https://opencode.ai/update/api/latest/desktop/opencode/opencode-desktop-linux-amd64.deb) · [ARM64](https://opencode.ai/update/api/latest/desktop/opencode/opencode-desktop-linux-arm64.deb) - **Linux(.rpm):** [x64](https://opencode.ai/update/api/latest/desktop/opencode/opencode-desktop-linux-x86_64.rpm) · [ARM64](https://opencode.ai/update/api/latest/desktop/opencode/opencode-desktop-linux-aarch64.rpm) - **Linux(AppImage):** [x64](https://opencode.ai/update/api/latest/desktop/opencode/opencode-desktop-linux-x86_64.AppImage) · [ARM64](https://opencode.ai/update/api/latest/desktop/opencode/opencode-desktop-linux-arm64.AppImage) ## Web 使用 `opencode pair` 指令存取 OpenCode Web 介面。 ```bash $ opencode pair Open a link to connect. Links work once and expire in 5 minutes. http://127.0.0.1:49374/auth/connect/... ``` ## Docker Docker 映像使用版本號作為標籤,例如 `ghcr.io/anomalyco/opencode:2.0.0`。若要在容器中執行伺服器,請參閱 [Docker](/cli/web#docker)。 --- ## 連接 OpenCode 內建支援許多 LLM 供應商。你可以[在 TUI 中](/cli/providers)用 `/connect` 直接連接這些供應商。 參閱[供應商](/providers)以設定自訂供應商。 如果你想輕鬆使用最好的編碼模型,可以試試 [OpenCode 控制台](/console)。 你也可以試試 [OpenCode Go](/console/go),這是每月 $10 的訂閱 方案,讓你使用最好的編碼模型。 --- ## 自訂 編輯 [OpenCode config](/config)、[載入外掛](/plugins)、[連接 MCP 伺服器](/mcp-servers)或[建立指令](/commands),打造適合你的 OpenCode。終端機介面的主題與快捷鍵請參閱 [CLI 設定](/cli/config)。 --- ## 學習 若想深入學習 OpenCode,可以參考 Boot.dev 與我們團隊討論後製作的 [AI Coding with OpenCode](https://www.boot.dev/courses/learn-ai-coding) 課程。教材和影片都可免費閱讀及觀看,部分互動功能則可能需要付費。