Feature request: persistent project-level session name
Resolved 💬 3 comments Opened Mar 11, 2026 by cristoslc Closed May 27, 2026
Feature Request
Problem
When working in a project, I want the session window to always be named a specific thing (e.g., the project name). Currently, /rename is the only way to set the session name, but it resets on /clear since that creates a new session.
Attempted workarounds
- SessionStart hooks: Can inject
additionalContextasking Claude to run/rename, but Claude can't invoke slash commands programmatically - Skills: No exposed API or storage mechanism for session metadata, so a custom skill can't replicate
/rename - CLAUDE.md instructions: Would burn tokens every turn just to remind Claude to rename
Proposed solution
A project-level setting in .claude/settings.json for a default session name:
{
"sessionName": "swain"
}
This would automatically apply the name on startup, clear, and resume events without requiring manual /rename each time.
Alternatives considered
- A
--session-nameCLI flag (useful but doesn't help with/clear) - Making
/renamesurvive/clear(would require changing/clearsemantics) - A hookable
setSessionName()API exposed to skills/hooks
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗