Skip to content

Desktop app loses session history after sessions are closed #67118

Description

@lucasvicente-com-ar

Description

The Claude Code desktop app (Windows) does not persist session history in the sidebar after sessions are closed. Only currently active sessions appear in the UI.

Steps to reproduce

  1. Open Claude Code desktop app on Windows
  2. Create several sessions across different project directories
  3. Close the sessions normally
  4. Reopen the app — only the most recent/active sessions appear in the sidebar

Expected behavior

All previous sessions should remain visible in the session list/sidebar, similar to how they were displayed before.

Actual behavior

Only currently running sessions are listed. Historical sessions disappear from the UI once closed.

Root cause investigation

  • Session transcripts (.jsonl files) are intact in ~/.claude/projects/no data loss.
  • The ~/.claude/sessions/ directory only contains JSON files for currently active sessions (PID-based files). When a session ends, its index file is cleaned up.
  • The desktop app does not re-scan ~/.claude/projects/ to rebuild the session list from existing transcripts.
  • claude --resume from the CLI correctly finds and lists all sessions for a given project directory by reading the transcript files directly.

Environment

  • Platform: Windows 11 Pro (10.0.26200)
  • Claude Code version: 2.1.170
  • Entrypoint: claude-desktop

Workaround

Users can resume old sessions via the CLI:

cd "path/to/project"
claude --resume

This reads the .jsonl transcripts directly and lists all available sessions for that project.

🤖 Generated with Claude Code

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:desktopbugSomething isn't workingplatform:windowsIssue specifically occurs on WindowsstaleIssue is inactive

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions