Homebrew-managed Codex CLI installs can lag behind the current cask when local package metadata has not been refreshed. Upgrading the Codex cask replaces the binary that the terminal resolves as codex while keeping local Codex login and configuration state separate from the package itself.
OpenAI lists Homebrew as a Codex CLI install option, and Homebrew publishes Codex as the codex cask. Use the cask-specific upgrade command after updating Homebrew so the package manager checks the cask record rather than relying on formula resolution.
If the installed cask is already current, Homebrew reports that no upgrade is needed and leaves the existing binary in place. The upgrade check is complete when the active shell resolves codex from the Homebrew prefix and codex --version prints the release expected for that machine.
Related: How to install Codex CLI with Homebrew
Related: How to check Codex CLI version
$ brew update ==> Updating Homebrew... Already up-to-date.
$ brew upgrade --cask codex Warning: Not upgrading codex, the latest version is already installed
When a newer cask is available, Homebrew downloads the replacement package and relinks the codex binary instead of printing the already-installed warning.
$ command -v codex /home/linuxbrew/.linuxbrew/bin/codex
The path depends on the Homebrew prefix. Common macOS paths are /opt/homebrew/bin/codex and /usr/local/bin/codex.
$ codex --version codex-cli 0.139.0
The version number changes as new releases ship.
Related: How to check Codex CLI version
$ codex
If the session opens with the wrong account or sign-in method, log out and start the intended login flow.
Related: How to log out of Codex
Related: How to log in to Codex with device authentication