Session history missing - sessions-index.json not created for all projects

Resolved 💬 3 comments Opened Jan 17, 2026 by kdmyers56 Closed Jan 17, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Session history does not show all previous sessions. Investigation reveals that sessions-index.json files are not being created for all project directories, causing sessions to not appear in the UI even though the session data files (.jsonl) exist on disk.

Evidence from my system:

Project WITH index (sessions appear in UI):

~/.claude/projects/-Users-kmyers-atomo-commercialization-dsl/
  - sessions-index.json ✓
  - 4 session .jsonl files

Project WITHOUT index (sessions missing from UI):

~/.claude/projects/-Users-kmyers-Kelly-Customers-Definium-Therapeutic--MindMed----Matt-Wiley-/
  - NO sessions-index.json
  - 4 session .jsonl files exist (30MB+ of data)

Another project WITHOUT index:

~/.claude/projects/-Users-kmyers-Kelly-Customers-White-Plains-Hospital---Tony-Mercando--WPH-Data/
  - NO sessions-index.json  
  - 2 session .jsonl files exist

The session data is intact but not indexed, so it doesn't appear in session history.

What Should Happen?

All sessions should appear in session history, with sessions-index.json files created and maintained for each project directory where sessions exist.

Error Messages/Logs

Steps to Reproduce

  1. Use Claude Code across multiple different project directories over time
  2. Create sessions in each project
  3. Check session history in the UI - only some sessions appear
  4. Inspect ~/.claude/projects/ to find that some project folders have sessions-index.json and some don't
  5. The projects without the index file have their sessions missing from the UI, despite the .jsonl session files existing

Claude Model

None

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

1.1.351 (Claude Desktop App)

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

Feature Request: Please add a way to rebuild/regenerate the session index from existing .jsonl files (e.g., a CLI command like claude sessions reindex or automatic detection of orphaned session files).

The session data is all intact - it's just the index that's missing. Having a rebuild option would recover all the "lost" sessions.

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗