CLI Commands Reference
Quick reference for npx t3@latest, t3, t3 serve, t3 service install, t3 up, t3 update, t3 doctor, and t3 uninstall.
Whether you run T3 Code on a headless Linux box or want quick maintenance commands alongside the desktop app, this reference lists the verified t3 CLI subcommands, flags, and daemon tools.
1. Starting & Trying T3 Code
# Run once without installing globally (requires Node.js)
npx t3@latest
# Start the local backend server and open the Web UI in your browser
t3
# Start only the backend server without launching a browser
t3 serveCommon t3 serve Flags
| Flag | Purpose | Example |
|---|---|---|
--port <number> | Override the listening port (default 3773) | t3 serve --port 3774 |
--host <address> | Bind a specific IP/interface (e.g., 127.0.0.1 or Tailscale IP) | t3 serve --host 100.x.y.z |
--no-browser | Skip opening a browser tab automatically | t3 serve --port 3773 --no-browser |
--base-dir <path> | Override the root data directory (~/.t3 by default) | t3 serve --base-dir /data/t3code |
2. Remote Access Wizard: t3 up
t3 upWalks you interactively through setting up remote device access—choosing between T3 Connect, Tailscale, or LAN—signing in, and ensuring the background server stays reachable.
3. Background Service Management: t3 service
Supported on macOS (launchd) and Linux (systemd user service with loginctl enable-linger). Not directly supported for native background services on Windows.
| Command | Action |
|---|---|
t3 service install | Register and start the persistent background service |
t3 service status | Show running state, startup status, and log file path |
t3 service restart | Restart the running background service |
t3 service update | Upgrade the background service launcher to the latest release |
t3 service uninstall | Stop and unregister the service (keeps projects, threads, and settings) |
4. Upgrading, Diagnostics & Uninstalling
| Command | Action |
|---|---|
t3 update | Upgrade the CLI installation to the latest release |
t3 doctor | Inspect SQLite store health and report reclaimable disk space |
t3 doctor --fix | Execute recommended safe repairs and compact SQLite state (run with server stopped) |
t3 uninstall | Remove the CLI, background service, and local T3 Code data |
5. Check Your Installed Version's Live Flags
Because pingdotgg/t3code ships updates frequently, run --help directly against your installed binary whenever checking newer flags:
t3 --help
t3 serve --help
t3 service --help
t3 doctor --help