5 小时窗口怎么算?

Codex 的 5 小时窗口从上一个窗口结束后你发的第一条消息开始,固定 5 小时;Claude 是滚动的 5 小时会话。两家都不是固定条数。

Codex

固定窗口:上一个窗口结束后,你发的第一条消息开启新的 5 小时。

一个窗口里能做多少不是固定条数:模型、上下文大小、推理档位、工具调用、检索和缓存都会改变一个任务的消耗,所以周额度还有剩,5 小时也可能不到点就用完。恢复时间看 chatgpt.com/codex/settings/usage 或 CLI 里的 /status。Business Premium 席位没有 5 小时限制。

官方原文

The five-hour limit determines how much usage is included in each window. A new window starts when you send your first message in Work or Codex after the previous window ends.
OpenAI Help Center · Managing usage with GPT-6 Astra in Work and Codex
You may reach the five-hour limit before five hours have passed, even if you still have weekly usage remaining. Check Settings → Usage for your current allowance and reset times. Limits vary by plan.
OpenAI Help Center · Managing usage with GPT-6 Astra in Work and Codex
These estimates are not fixed message limits; check your usage dashboard for current limits and reset times.
OpenAI Developers · Codex pricing
Premium seats have 5x the included usage of Standard seats, with the benefit of no 5-hour limit so users can maximize uninterrupted session time
OpenAI Help Center · ChatGPT Business models and limits

Claude

滚动的 5 小时会话;精确恢复时间在设置 › 用量和 /usage 里。

Anthropic 称之为滚动的 5 小时会话窗口,没有固定条数:消息长度、附件、对话长度、模型、effort 档位和工具都算。用量同时计入会话额度和周额度。官方没写窗口具体从哪一刻开始;Claude Code 会把恢复时间作为字段(five_hour.resets_at)显示,到点即清掉这个窗口。

官方原文

Your session-based usage limit will reset every five hours.
Claude Help Center · What is the Pro plan?
Every plan has usage limits that reset on a rolling five-hour session window, and paid plans add weekly limits on top.
claude.com · Pricing FAQ
How much you can do depends on the length and complexity of your conversations, the model you choose, and the features you use, so there's no fixed message count.
claude.com · Pricing FAQ
Usage counts against the session and weekly allowances at the same time. A single burst of heavy activity, such as a large workflow fanout, can exhaust the weekly allowance before the session window resets.
Claude Code docs · Error reference
Claude Code drops a window once its resets_at time passes.
Claude Code docs · Customize your status line

实际影响

  • 真正的倒计时在你账号里(Settings → Usage / 设置 › 用量),不在本站。
  • 一次大动作(长 agent 任务、并行扇出)几分钟就能把一个窗口用空,时钟不会因此变慢。

官方原文于 2026-09-15 对照在线文档核对。

答案依据 OpenAI、Anthropic 官方文档,每页附原文与链接 · 不代表官方背书。