Back to feed
Dev.to
Dev.to
5/11/2026
Why every Ghostty tab said 'Claude Code' (and the 30-line zsh hook that fixed it)

Why every Ghostty tab said 'Claude Code' (and the 30-line zsh hook that fixed it)

Short summary

When running Claude Code in Ghostty, tab titles become noise as both tools overwrite them. This guide explains the two layers of misbehavior and provides a 30-line zsh hook solution that restores meaningful titles: shows git repo names by default, adds a 👾 marker when Claude runs, and automatically reverts when the session ends. Configuration included for both Ghostty and zsh.

  • Ghostty and Claude Code both clobber terminal tab titles, creating confusion in multi-pane workflows
  • Solution: disable both title systems and manage titles via zsh hooks (chpwd, precmd, preexec)
  • Result: automatic repo-name titles with 👾 marker when Claude is running, zero manual intervention

Generated with AI, which can make mistakes.

Is this a good recommendation for you?

Explore more