The cache countdown and the reminder
Send the next message while the cache is alive, and a conversation of any size costs only the message.
Partly built. The ring and the reminder work in the studio for Claude Code sessions. The iPhone app draws the ring in the row of a session and shows the reminder too; that version has been built and tried on a sample studio, and it reaches a phone only with the next build of the app.
A small ring beside each finished Claude Code session fills as the time its cache is kept runs out. Ten minutes before the end, for a big session, a reminder arrives. Both exist for one reason: a message sent into a cache that is gone makes the provider read the whole conversation again, and that comes out of your usage limit.
It pays to send the next message while the cache is alive. It pays to know when it is not.
Why the cache matters
While a session's cache is alive, a new message costs only the message. The rest of the conversation is read from the cache, at a small part of the price. When the cache is gone, the next message sends the whole history again as new input. For a conversation of 590,000 tokens that is one short question that eats a visible slice of a five-hour limit.
How long a cache is kept is not a guess. Every request writes either 5 minutes or 1 hour, and the answer records which. The sessions you work in yourself are one hour. Five minutes shows up in background runs and when an account has gone over to paid extra usage. In the real session files the studio was checked against, every cache was alive up to 59 minutes after the last call and every one was gone from 62 minutes, so the line is the hour.
The clock restarts at each call of the session's own thread, and a helper that works for the session does not keep it warm. The studio cannot ask the provider whether a cache is alive: any question is a request, costs something and restarts the clock. So it counts from the recorded time, and confirms its count from the answer to your next message.
What the ring shows
In the list of sessions, a Claude Code session that is no longer working has a ring after its state. It fills from the session's last call to the end of the time its cache is kept, in green. In the last ten minutes it turns orange, and a cache kept five minutes turns orange for its last third. When the cache is gone the ring disappears. Hover it: The cache of this session is kept for 12 more minutes. After that, the next message sends 140k tokens again. The ring moves only while the window is in use.

A session that works shows no ring, since each step it takes restarts the cache.
The reminder ten minutes before
A reminder comes when all of this is true: the session is Claude Code, its cache is kept an hour, it has stopped working, and its conversation holds at least 100,000 tokens. A smaller one costs little to send again, and a five-minute cache would be announced two minutes after the turn ended. The reminder is raised once for each call of the session, and it closes by itself when the session works again or the cache runs out. Its words: The cache of this session runs out in 10 minutes. and Continue after that, and 140k tokens are sent again.

It is always in the column of alerts. A Windows notice and a Telegram message follow when the AigoPilot window is not in front of you; see Windows notifications and sound and Telegram alerts.
To turn it off, open Settings, then Notices under More, and untick has ten minutes left before its cache runs out. The notice stops, and the alert still shows in the column. A project's own notices can be switched off in that project's settings.
Before you send into a cold cache
When you click into the box of a session whose cache has probably run out, a note appears above it: The cache of this session has probably expired, how long it has been, and about how many tokens this message sends again. If you only want a report of the work, a fresh session in the same project reads the files and costs almost nothing. Compacting does not avoid the cost, because summing up the conversation has to read all of it once.
Why Codex has no ring
Only Claude Code states, in every request, how long it keeps the cache. Codex does not say. Measured on real Codex sessions, its cache was usually alive up to about 40 minutes, then about half the time until two hours, then mostly gone, with some alive after ten hours. There is no sharp line, so a countdown would be invented, and the studio draws none. Grok sessions get no ring either.
Small tips
Hover the ring for minutes left and tokens
The tooltip says how many more minutes the cache is kept and how many tokens the next message sends again when it is gone.
Turn the reminder off for one project
A project's own notices can be switched off in its settings, and that stops the Windows notice and the Telegram message for its sessions. The alert still shows in the column.
Read the note above the box before you send
Click into the box of a session whose cache has probably run out, and a note says how long it has been and about how many tokens this message sends again.
Questions
How long does Claude Code keep the cache of a session?
Either five minutes or one hour, and each request records which. The sessions you work in yourself are usually one hour. In the session files checked, caches were alive up to 59 minutes and gone from 62.
Why is there no ring for my Codex sessions?
Codex does not say how long it keeps its cache, and measured on real sessions there is no sharp line, so any countdown would be invented.