Expose per-message timestamps to Claude's context for time-aware reasoning
Preflight Checklist
- [x] I have searched existing requests and this feature hasn't been requested yet
- [x] This is a single feature request (not multiple features)
Problem Statement
Claude Code has no awareness of elapsed time between messages. The conversation transcript .jsonl already contains timestamps per API call, but they aren't injected into Claude's context. This means Claude cannot:
- Self-correct on wasted effort. If Claude spends 15 minutes going in circles on an approach that isn't working, it has no way to notice. The user has to be the one to say "stop, try something else." With timestamps, Claude could recognize "I've been at this for 10 minutes with no progress; let me step back and try a different approach."
- Learn from time-spent patterns. If Claude could correlate approaches with time spent, it could write to memory: "SVG filter approach took 20 minutes and failed, CSS-only approach took 3 minutes and worked." Next session, it makes the better choice immediately.
- Understand session continuity. When a conversation is resumed after compaction, Claude has no idea if the user stepped away for 8 hours or 8 seconds. In a real case: Claude told me to "go get some sleep" at 2pm because the summary mentioned it was late the previous night; it had no idea a whole night had passed.
- Gauge urgency and pacing. A user firing off messages every 10 seconds is in a different mode than one responding every 5 minutes. Time awareness lets Claude match the user's pace and priorities.
Why This Matters
This isn't a cosmetic feature; it's a reasoning primitive. Time is one of the most basic signals humans use to evaluate whether an approach is working. Without it, Claude is flying blind on effort vs. progress. With it, Claude gains genuine self-awareness about its own performance.
Prior Issues
- #18582 - Same request, auto-closed for inactivity (not reviewed by a human)
- #2441, #4173, #24349, #28717 - Related but focused on showing timestamps in the UI for the user, not exposing them to Claude's reasoning
Proposed Solution
Inject a timestamp (ISO 8601 or Unix epoch) with each user message in Claude's context. The data already exists in the transcript so this is literally just about surfacing it! :)
Alternative Solutions
If injecting timestamps into every message is a concern for context window usage, an
alternative would be to expose a lightweight time tool that Claude can call on demand;
similar to how the Bash tool works but limited to returning the current UTC timestamp and
optionally the elapsed time since the last user message. This would be zero-cost when not
used and available when Claude needs it (e.g., before deciding whether to pivot strategies
or when resuming a compacted session). The downside is that Claude would need to know to
call it, whereas injected timestamps are passively available and require no decision-making
overhead.
Priority
High - Significant impact on productivity
Feature Category
Configuration and settings
Use Case Example
Example:
[2026-03-09T01:47:00Z] User: we've been at this for an hour, let's try a simpler approach
[2026-03-09T13:42:00Z] User: ok what's next
Claude would immediately see the 12-hour gap and understand context has shifted.
Additional Context
This emerged during a real multi-hour session building a B2B marketing site. Claude spent
roughly 45 minutes attempting increasingly complex click-to-zoom card transitions; cloning
DOM elements, reparenting nodes, fighting z-index stacking contexts; none of which worked.
The user eventually had to intervene and say "we've been at this for an hour, just do a
simple fade." Claude had no mechanism to recognize the time sink on its own.
In the same session, the conversation hit the context limit and was resumed via compaction.
The summary mentioned the user had an 8am meeting and it was nearly 1am. When the user
returned the next afternoon, Claude said "go get some sleep" because it had no way to
distinguish a 12-hour gap from a 12-second one. Per-message timestamps would have made
this immediately obvious.
Claude Code already supports persistent memory files where Claude records patterns and
solutions across sessions. Timestamps would make this dramatically more useful instead
of just recording "approach X worked," Claude could record "approach X worked in 3 minutes,
approach Y failed after 15 minutes." This creates a feedback loop where Claude gets
measurably better at choosing strategies over time, which is the closest thing to genuine
self-improvement currently possible within the tool.
This feature has been requested at least 5 times (#18582, #2441, #4173, #24349, #28717)
but prior issues either focused on UI-side timestamps (visible to the user, not to Claude)
or were auto-closed for inactivity before being reviewed. The underlying data already exists
in the .jsonl transcript, this is a matter of piping it into the context window.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗