Feature request: /archive command to close/archive current session
Feature Request
Add a /archive command (or similar) that programmatically archives/closes the current Claude Code conversation session.
Use Case
In project workflows, we use custom skills (slash commands) like /task-done that finalize work: run lint, tests, code review, commit, and update changelog. After all steps complete, the conversation is effectively done — there's no reason to keep it active.
Currently there's no way to archive/close the session from within a skill. We can only remind the user to do it manually.
Proposed Solution
A /archive or --archive-session command that:
- Marks the current session as archived/completed
- Optionally adds a summary/label for the archived session
- Can be called programmatically from custom skills
This would enable fully automated task workflows where the session cleanly closes after task completion.
Workaround
Currently we add a manual reminder at the end of our /task-done skill asking the user to archive the chat themselves.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗