Repository navigation
Description
What version of Codex CLI is running?
0.151.0
What subscription do you have?
ChatGPT Plus
Which model were you using?
gpt-5.6-sol
What platform is your computer?
Linux 6.8.0-138-generic x86_64 x86_64
What terminal emulator and version are you using (if applicable)?
No response
Codex doctor report
What issue are you seeing?
The 5h ("primary") rate-limit window went from 0% to 100% in 23 minutes, while the
weekly ("secondary") window moved only 55% -> 56% over the same period. The two
counters disagree by roughly two orders of magnitude for identical traffic, which
is what makes me think this is a metering bug rather than just heavy usage.
Numbers are taken from the rate_limits snapshots recorded in the session
rollout files under ~/.codex/sessions:
| Timestamp (UTC) | primary used_percent | secondary used_percent |
|---|---|---|
| 2026-09-01 07:22:07 | 0% | 55% |
| 2026-09-01 07:45:43 | 100% | 56% |
primary: window_minutes=300, resets_at=1788265323
secondary: window_minutes=10080, resets_at=1788765541
plan_type: plus
Actual traffic in that 23m41s window, summed across both sessions:
- 209 API calls
- 26,689,078 input tokens, of which 26,217,472 were cached (98.2%)
- 471,606 uncached input tokens
- 99,680 output tokens (34,237 reasoning)
So ~470k uncached input tokens and ~100k output tokens consumed the entire 5h
allowance, but only 1 percentage point of the weekly allowance.
I do not know how the primary window is weighted, but if cached input is being
billed against the 5h bucket at or near the uncached rate, that would explain
both the speed of the burn and the divergence from the weekly counter.
What steps can reproduce the bug?
- Start two Codex CLI sessions concurrently, both on
gpt-5.6-sol, each with a
large accumulated context (~20M cumulative input tokens, ~96% cache hit rate). - Send one prompt to each and let them run agentic tool loops for ~20 minutes.
- Watch the
rate_limitsvalues in the session rollout JSONL (or the limit
display in the TUI).
Thread / session IDs:
- 01a056db-e496-7460-8eca-cdb640bf4dda
- 01a059ab-aa44-7720-8839-354309ccb041
Both sessions were still mid-task when the limit hit 100%.
What is the expected behavior?
Two ~20-minute sessions should not exhaust a full 5h Plus allowance, and the 5h
and weekly counters should move in proportion to each other for the same traffic.
A 100pp move in one and a 1pp move in the other suggests one of the two is
computed incorrectly.
Additional information
No response
Activity
github-actions commentedon Sep 1, 2026
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
osavoskin commentedon Sep 27, 2026
Same here. I’m seeing unexpectedly severe Codex CLI quota consumption as well.
A single session started with my quota at 100% consumed essentially the entire available quota in just a few minutes. The parent agent used
gpt-5.6-solat medium reasoning, while 6 explorer agents usedgpt-5.6-terraat high reasoning.The session logged ~28.96M input tokens, but ~27.67M of those were cached. Only ~1.29M input tokens were uncached, yet the fresh quota was exhausted.
Breakdown:
So only ~4–5% of the input was actually uncached/new input.
The session did spawn several explorer agents and performed many repository operations, but given that ~95% of the input traffic was cached - and cached input is priced/accounted at a substantially lower rate than uncached input - the observed quota depletion seems disproportionately high.
There is something seriously wrong. I have been using Codex for a long time, but it has never spent the entire quota on a single task that it did not even finish!
hnguyen-brightspot commentedon Sep 29, 2026
I would suggest the opposite, where the 5 hours limit is ok, but allow users to temporarily turn off the 5-hour usage limit when needed. I understand the need for the weekly limit. The core problem is that the five-hour limit controls not just how much I can use, but when I am allowed to use it. Sometimes I have a long, focused coding session, a deadline, or a complex task that I want to finish while the context is fresh.
This is particularly frustrating when I have a usage reset available. If I have exhausted my five-hour allowance but used only a small portion of my weekly allowance, applying the reset feels wasteful: I am resetting a weekly budget that I have barely touched, mainly to get past the short-term restriction. The alternative is to keep working in limited bursts and waiting for each window to reopen. By the time I have used enough of the weekly allowance to make the reset worthwhile, the normal weekly reset may already be approaching. That leaves me choosing between using the reset inefficiently and delaying the work I actually need to do.
There should be an explicit, temporary option to lift the five-hour restriction and draw directly from my remaining weekly allowance. This would not mean unlimited usage or extra tokens. It would simply let me decide to spend my existing allowance sooner, with the understanding that I might have less—or nothing—left for the rest of the week.
A confirmation showing my remaining allowance and warning that it could be exhausted during the session would make that trade-off clear. The override could expire after the session or a chosen duration, with an option to turn it off earlier. The five-hour limit could remain the default safeguard, but users who knowingly accept the consequences should have more control over when they use their available capacity.