claude-code - 💡(How to fix) Fix Allow users to customize the terminal/tab title [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#52258Fetched 2026-04-24 06:11:58
View on GitHub
Comments
0
Participants
1
Timeline
4
Reactions
0
Participants
Timeline (top)
labeled ×3cross-referenced ×1
  • Claude Code already sets the terminal title — this would just expose control over it
  • Community plugins like TabChroma and iTerm2-claude-integration exist to work around this, showing demand for better tab identification
  • Escape sequences (\e]1;title\a) and AppleScript set name on sessions are both overwritten by Claude Code's TUI on every render cycle, so external solutions can't stick
  • The Stop hook can't solve this either, since escape sequences in hook output are captured by the TUI rather than passed to the terminal emulator

Root Cause

  • Claude Code already sets the terminal title — this would just expose control over it
  • Community plugins like TabChroma and iTerm2-claude-integration exist to work around this, showing demand for better tab identification
  • Escape sequences (\e]1;title\a) and AppleScript set name on sessions are both overwritten by Claude Code's TUI on every render cycle, so external solutions can't stick
  • The Stop hook can't solve this either, since escape sequences in hook output are captured by the TUI rather than passed to the terminal emulator
RAW_BUFFERClick to expand / collapse

Problem

When running multiple Claude Code sessions in separate terminal tabs, there's no way to distinguish them. Claude Code actively manages the terminal title (setting it to spinner + task description), which overwrites any title set externally via escape sequences or AppleScript.

This makes it hard to navigate between tabs when working on different tasks across multiple sessions.

Proposed Solution

Allow users to set a custom title prefix or override for the terminal tab. This could be:

  • A /title "my label" slash command that prepends or replaces the tab title
  • A hook event (e.g., SessionStart or a new TitleChange event) that lets users customize the title
  • A config option in settings.json for a title template (e.g., "titleFormat": "{project}: {status}")

Context

  • Claude Code already sets the terminal title — this would just expose control over it
  • Community plugins like TabChroma and iTerm2-claude-integration exist to work around this, showing demand for better tab identification
  • Escape sequences (\e]1;title\a) and AppleScript set name on sessions are both overwritten by Claude Code's TUI on every render cycle, so external solutions can't stick
  • The Stop hook can't solve this either, since escape sequences in hook output are captured by the TUI rather than passed to the terminal emulator

Use Case

A user working on multiple projects simultaneously (e.g., "coach email", "whoop dashboard", "sleepcheck") can label each tab so they can quickly find the right session.

extent analysis

TL;DR

Implementing a custom title prefix or override feature in Claude Code would allow users to distinguish between multiple sessions in separate terminal tabs.

Guidance

  • Introduce a /title slash command to prepend or replace the tab title, providing users with a straightforward way to customize the title.
  • Add a TitleChange hook event to enable users to customize the title programmatically, offering more flexibility.
  • Consider adding a titleFormat config option in settings.json to allow users to define a custom title template, such as "titleFormat": "{project}: {status}".
  • Explore integrating with existing community plugins, like TabChroma and iTerm2-claude-integration, to leverage their solutions and user demand.

Example

// settings.json example
{
  "titleFormat": "{project}: {status}"
}

Notes

The proposed solution should be designed to coexist with Claude Code's existing terminal title management, ensuring that user-defined titles are not overwritten by the TUI.

Recommendation

Apply a workaround by introducing a custom title prefix or override feature, as it directly addresses the user's need to distinguish between multiple sessions and provides a flexible solution.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING