This document describes how to automate Claude Code installation and authentication on headless VPS machines without requiring browser-based OAuth authentication.
Claude Code's interactive mode requires OAuth authentication via a web browser. On headless VPS machines without a GUI, this creates a chicken-and-egg problem: you can't authenticate without a browser, but the machine has no browser.
While claude -p (print mode) works with just ANTHROPIC_API_KEY, interactive mode always launches an onboarding wizard that requires browser authentication.