Support persistent sessionName and sessionColor in settings.json
Resolved 💬 3 comments Opened Mar 31, 2026 by valberhcustodio Closed Apr 4, 2026
Feature Request
Problem
/rename and /color are session-scoped — they are lost when running /clear (or /reset). There is no way to configure a persistent session name or color per project via settings.json.
For users working on multiple projects simultaneously, having a distinct name and color per project helps with quick identification of which terminal/session belongs to which project.
Proposed Solution
Add support for sessionName and sessionColor keys in project-level .claude/settings.json (or .claude/settings.local.json):
{
"sessionName": "MyProject",
"sessionColor": "green"
}
Behavior:
- When a session starts in a directory with these settings, the name and color are applied automatically
/clearshould preserve these values since they come from configuration, not session state/renameand/colorcan still override them for the current session- Project-level settings override user-level settings (following existing precedence)
Alternatives Considered
- Shell aliases (
alias proj="claude -n MyProject --color green") — works for startup but not after/clear - Running
/rename+/colorafter every/clear— tedious and error-prone - Hooks —
SessionStarthooks exist but cannot set session name/color programmatically
Additional Context
/renameand/coloralready work perfectly — this is just about making them configurable via settings- The
--nameand--colorCLI flags exist but also don't survive/clear - This would follow the same pattern as other project-level settings in
.claude/settings.json
🤖 Generated with Claude Code
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗