The local-first coding agent
Switchback does most of its work on a local model and calls in the hosted model you choose only for the hard parts. Every handoff tells you which model ran and why.
curl -fsSL https://switchback.sh/install.sh | sh - Runs on macOS · Linux · Windows
- Clients Terminal · VS Code
- Docs Read the docs
- Source GitHub ↗
❯ where is the retry logic? ↳ ✓ explore find retry logic · local · 6 tool calls Retries live in src/http/client.ts:88 … ❯ add exponential backoff with jitter ✓ edit src/http/client.ts ✗ bash bun test src/http ✗ bash bun test src/http/client.test.ts ✗ bash bun test --bail src/http ☁ remote · 3 consecutive tool errors ✓ edit src/http/client.ts ✓ bash bun test src/http
Local first, remote when it matters
A transparent router picks the model for every call. You see each decision and the rule behind it, and you can override it at any time with /local or /remote.
- DefaultStart local
Turns run on your local model, at no cost per token.
- WatchNotice trouble
Loops, malformed tool calls, repeated failures, or a context that won't fit.
- EscalateCall in help
Hand the turn to your remote model automatically, or ask you first.
- CapStay in budget
Remote spend stops at your daily and monthly limits. Local never silently costs money.
What you get
- ROUTINGLocal by default Each model call goes to the model on your machine (Ollama, llama.cpp, LM Studio, vLLM) unless the router has a reason to escalate, and it prints the reason.
- SUBAGENTSParallel helpers Searches and side tasks run as subagents with their own context and routing. The built-in explore agent always stays local. Claude Code agent files work as they are.
- REVIEWDraft locally, review remotely A stronger model can review each change the local model makes, and the local model fixes what it finds. A review costs cents.
- PRIVACYPrivate files stay private List paths that must never reach a remote model. Once a session reads one, it stays local for good. Credentials are redacted before anything goes out.
- SPENDBudgets you set Daily and monthly caps on remote spend. The status line shows what a session cost and what it saved against running everything remotely.
- PROVIDERSAny provider, equal terms OpenAI, Anthropic, DeepSeek, Gemini, Bedrock, Vertex, Claude Platform on AWS, Microsoft Foundry, or any OpenAI-compatible API. None is a default.
In VS Code, too
The extension is the same engine with a chat view in the sidebar. It shares live sessions with the terminal, so you can start a task in one and pick it up in the other.
- Install Switchback and the extension
curl -fsSL https://switchback.sh/install.sh | sh -s -- --vscodeUses the first editor command it finds:
code,code-insiders,codium, orcursor. - Or just the extension
Download the
.vsixfor your platform from the latest release and choose Install from VSIX… in the Extensions view. It includes the engine.
- Edits Reviewed in the diff editor
- Context Selection, file, and problems
- Status bar Route, last tier, and cost
- Config Shared with the CLI
Install
One binary, no runtime to install. The script picks the build for your machine, checks it against the release's checksums, and puts it in ~/.local/bin. It never uses sudo or edits your shell profile.
- Install
curl -fsSL https://switchback.sh/install.sh | shOptions go after
sh -s --:--version 0.5.0for a specific release,--dir ~/binfor another directory. Read the script - Choose your models
switchback initFinds your local model server and asks which remote provider, if any, to escalate to.
- Start in a project
switchbackOr run one prompt headless:
switchback run "explain src/index.ts". - On Windows
irm https://switchback.sh/install.ps1 | iexIn PowerShell, without administrator rights. It installs to
~\.local\binand adds that to your user PATH. Read the script
Running Switchback for a team?
A Switchback site sets which models and providers your people may use, caps spend, and shows usage by member and model. Members connect with switchback login --site <id>. Switchback never sends prompts or code to the site.