-
Notifications
You must be signed in to change notification settings - Fork 5.5k
Description
Preflight Checklist
- I have searched existing requests and this feature hasn't been requested yet
- This is a single feature request (not multiple features)
Problem Statement
Title: [FEATURE]
Description:
Currently, there's no convenient way to view or delete sessions without using claude --resume. This creates two UX problems:
-
No way to list sessions without resuming -
claude --resumeforces an interactive selection interface. Users who just want to see their session history must navigate through the interactive menu. -
No way to delete sessions - There's no CLI command or slash command to delete a specific session by ID. While
claude --resumeclearly has access to the session file paths (since it can list them), there's no corresponding delete functionality.
Possible duplicate issue #13780
Proposed Solution
Add two slash commands that mirror standard session management workflows:
/list-sessions # Lists all previous sessions with ID, timestamp, and initial prompt
/delete-session <id> # Deletes a specific session by ID
Or alternatively, extend the CLI:
claude --list-sessions
claude --delete-session <session-id>
Why this matters:
- Users want to audit their session history without being forced into resume mode
- Session cleanup should be straightforward (currently requires manual directory navigation)
- This would make Claude Code's session management more consistent with standard CLI tools
- The session storage location is already known to the application
Alternative Solutions
No response
Priority
Medium - Would be very helpful
Feature Category
CLI commands and flags
Use Case Example
As a developer, I want to review my past sessions, identify ones I no longer need, and delete them without navigating ~/.claude/projects/ manually or using --resume in an unintended way.
Additional Context
No response