claude-code - 💡(How to fix) Fix Feature Request: Persistent conversation history with infinite scroll (like Cursor) [2 comments, 3 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#45107Fetched 2026-04-09 08:13:06
View on GitHub
Comments
2
Participants
3
Timeline
4
Reactions
0
Author
Timeline (top)
commented ×2labeled ×2

When Claude Code's context window is full, older messages are compressed/summarized and removed from the UI. Users can no longer scroll up to view earlier parts of the conversation.

Cursor IDE handles this differently — it stores conversation history separately from the active context, allowing users to scroll through the full chat history regardless of context window limits.

Root Cause

  • Users lose visibility into what was discussed, what code was written, and what decisions were made earlier in a long session
  • This is especially painful during large implementation tasks spanning many files and decisions
  • Cursor already implements this UX pattern — users familiar with Cursor expect the same behavior in Claude Code
  • The raw data already exists in .jsonl files; it just needs to be surfaced in the UI
RAW_BUFFERClick to expand / collapse

Summary

When Claude Code's context window is full, older messages are compressed/summarized and removed from the UI. Users can no longer scroll up to view earlier parts of the conversation.

Cursor IDE handles this differently — it stores conversation history separately from the active context, allowing users to scroll through the full chat history regardless of context window limits.

Current Behavior

  • When the context window is exhausted, Claude Code auto-summarizes older messages
  • The summarized messages disappear from the chat UI entirely
  • Users can only see the active context window worth of messages on screen
  • Full history is saved to .jsonl files locally but is not surfaced in the UI

Expected Behavior

  • All conversation messages should remain visible in the UI via scrolling, even after context compression occurs
  • The underlying context sent to the model can still be compressed/summarized (this is fine and expected)
  • The UI display layer should be decoupled from the model context — store and render the full message log independently

Why This Matters

  • Users lose visibility into what was discussed, what code was written, and what decisions were made earlier in a long session
  • This is especially painful during large implementation tasks spanning many files and decisions
  • Cursor already implements this UX pattern — users familiar with Cursor expect the same behavior in Claude Code
  • The raw data already exists in .jsonl files; it just needs to be surfaced in the UI

Proposed Solution

Decouple the chat UI history from the model context window:

  1. Store all messages to disk as they occur (already done via .jsonl — data exists)
  2. Render messages from the persisted log, not from the active context
  3. When context compression happens, the model gets the summarized context but the UI continues showing the full history from disk
  4. Add a visual indicator (e.g. a subtle divider or label) showing where context compression occurred, so users understand which messages are "in context" vs. historical

References

  • Cursor: full conversation history is persisted and scrollable regardless of model context limits
  • Claude Code .jsonl files: ~/.claude/projects/<project>/**.jsonl — the data is already being saved, just not shown in the UI

extent analysis

TL;DR

Decoupling the chat UI history from the model context window by rendering messages from the persisted log in .jsonl files will allow users to scroll through the full conversation history.

Guidance

  • Store all messages in the .jsonl files as they occur, which is already being done, to ensure a complete conversation history is available.
  • Modify the UI to render messages from the persisted log in .jsonl files instead of relying on the active context window.
  • Implement a visual indicator to differentiate between messages that are within the current context and those that are historical, providing clarity to users.
  • Ensure that when context compression occurs, the model receives the summarized context while the UI continues to display the full history from the .jsonl files.

Example

No specific code example is provided due to the lack of direct code references in the issue, but the approach would involve reading from the .jsonl files to populate the UI with the full conversation history.

Notes

This solution assumes that the .jsonl files are correctly populated and accessible. It also requires careful implementation to ensure a seamless user experience, especially when displaying the visual indicator for context compression.

Recommendation

Apply the workaround by decoupling the chat UI history from the model context window, as it directly addresses the issue of lost conversation history visibility without requiring significant changes to the underlying model context handling.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING