Discord Download

AutoRouter in Terminal

Coding agents in your terminal route the same way as their apps. Turn each one on in the AutoRouter Mac app and pick AutoRouter in its model picker. Nothing to export and no API keys.

AutoRouter in Terminal How to pick AutoRouter in each CLI it works with.
Claude Code /model, or claude --model auto-claude-route. Setup
Codex CLI /model, or codex -m autorouter. Setup
OpenCode /models, or opencode -m autorouter/autorouter. Setup
Pi /model, with no restart. Setup
Plans The Claude, ChatGPT, Grok and Gemini plans you connect in AutoRouter, used first
Cost per turn Every turn shows its model, what it cost and why
Terminals Terminal, iTerm2, Ghostty or any other, on macOS 14 or later

Last updated November 20, 2026. See every supported app.

Set up your terminal agents

Four steps on your Mac. The app writes each CLI’s own settings, so there is nothing to paste.

In AutoRouter

  1. Install the Mac app Download AutoRouter, signed and notarized by Apple. Sign in or create a free account, then connect your plans.
  2. Turn on each CLI Click Enable on its row, in setup or in Settings, under Apps.

In your terminal

  1. Start a new session A session that was already open picks up the change once you start it again. Pi needs no restart.
  2. Pick AutoRouter Choose it in the CLI’s model picker. It also starts as each CLI’s default model.

What changes on your Mac

Each CLI’s own settings file. Turning a CLI off in AutoRouter puts its file back.

No shell changes

AutoRouter writes to each CLI’s settings file, not to your shell profile, and runs no local proxy. So a CLI routes the same in every terminal app and every window.

One file per CLI

  • Claude Code: ~/.claude/settings.json
  • Codex: ~/.codex/config.toml, shared with the Codex app
  • OpenCode: ~/.config/opencode/opencode.json
  • Pi: ~/.pi/agent/models.json

Your default comes back

The first time, AutoRouter becomes each CLI’s default model and remembers the one it replaced. A model you pick later stays yours. Turning a CLI off puts your old default back.

Limits

  • Mac only, macOS 14 or later.
  • Claude Code 2.1.242 or later with Node 22.18 or later, OpenCode 1.x or 2.x, and Pi 0.62 or later.
  • It sometimes misjudges how hard a task is. Rate the pick, or choose a model yourself.

Questions

What people ask about AutoRouter in the terminal.

Which terminal coding agents does AutoRouter work with?

Claude Code, the Codex CLI, OpenCode and Pi. Turn each on in the AutoRouter Mac app and pick AutoRouter in its model picker.

Which terminal apps does it work in?

Any of them, including Terminal, iTerm2 and Ghostty. Each CLI reads AutoRouter from its own settings file, so the terminal it runs in doesn’t matter.

Do I need to set environment variables?

No. AutoRouter writes each CLI’s settings file for you and adds nothing to your shell profile, so there is nothing to export or paste.

Which plans can I use in the terminal?

The plans you connect in AutoRouter: Claude, ChatGPT, Grok and Gemini. Claude Code and Codex also keep their own sign-ins. Free connects two subscriptions and Pro connects any number. Models no plan covers run on credits.

Is the Codex CLI set up separately from the Codex app?

No. Both read ~/.codex/config.toml, so turning Codex on in AutoRouter covers the app and the CLI.

Do I need to restart my sessions?

Start a new session after you turn a CLI on. OpenCode 2.x reloads on its own, and Pi needs no restart.

Does it work on Windows or Linux?

Not yet. AutoRouter is a Mac app for macOS 14 or later.

What does it cost?

Routing across your plans is free. Paid models bill at the provider’s price plus 10%. See pricing.

Pick AutoRouter in your terminal

Install the Mac app, turn your CLIs on and keep building.

Download AutoRouter for Mac