12-hour prompt caching: when OpenAI’s longer cache saves money
OpenAI’s 12-hour prompt caching costs 2.5x input to write and 0.1x to read. Break-even maths, when it beats the 30-minute default and how to enable it.
3 min read

In this article
12-hour prompt caching arrived in the OpenAI API on 20 October 2026. You can now keep a shared prompt prefix cached for at least 12 hours instead of the default 30 minutes. The catch is the write price: 2.5× the uncached input rate, double the 1.25× charged for a 30-minute write.
Cached reads cost 0.1× input on most models, and 0.05× on GPT-6.1 Sol, whichever lifetime you choose. So the longer cache pays only when a prefix is reused after the 30-minute window would have expired.
Sources checked on 26 October 2026. Features, prices and availability can change; confirm the linked primary sources before acting.
How 12-hour prompt caching is priced
You pay once to write the prefix and a small rate each time it is read. The write is the full charge for those tokens, not a surcharge on top.

The minimum cacheable prompt is 1,024 tokens on GPT-5.6 and later. The 12-hour option works with the Responses API on those models; earlier models use a separate 24-hour retention setting.
Break-even: when the longer cache pays
It pays from the third request when requests arrive more than 30 minutes apart. When they arrive more often, the default is cheaper.
With gaps over 30 minutes, the default cache expires between requests, so each request writes again at 1.25×. With the 12-hour cache you write once at 2.5× and then read at 0.1×.

A worked example: a 100,000-token prefix on GPT-6.1 Sol, used six times at two-hour intervals. The 30-minute default costs about $1.50 in writes. The 12-hour cache costs $0.50 to write plus five reads at $0.01, about $0.55.
A read within the 30-minute window refreshes it, so steady traffic keeps the default cache warm. A 30-minute read of a 12-hour entry keeps the later expiry; it does not restart the 12-hour clock.
Patterns that benefit, and ones that do not
Use the longer cache for large prefixes reused hours apart. Skip it for constant traffic or one-off prompts.
| Good fit | Poor fit |
|---|---|
| Agents that pause for human approval | Chatbots with steady traffic |
| Support sessions spread across a shift | One-off or rarely repeated prompts |
| Hourly or daily document batches with shared instructions | Prefixes that change per user or per request |
Put stable content first: system instructions, then tool definitions, then shared knowledge. Variable user input goes last, or nothing after it can be cached.
How to enable it and measure the result
Set the request-level option in the Responses API. A single breakpoint can also override it.
{
"model": "gpt-6.1-sol",
"prompt_cache_options": { "ttl": "12h" },
"input": [ … ]
}Then read the cached-token count in each response's usage data and compare spend for a week. Our verdict: enable 12-hour prompt caching per workload, only where requests are spaced more than 30 minutes apart and reused at least three times. Our guide to cutting LLM API costs with caching and batching covers the wider picture. For a cost review, see our API development and integration service.
Sources and further reading
- API changelog: 12-hour prompt caching — OpenAI
- Prompt caching guide — OpenAI
- API pricing — OpenAI
Image credits
Explanatory diagrams: Cloudsoft Zone, CC BY-SA 4.0. Featured photograph: PiDatacenters, CC BY-SA 4.0, via Wikimedia Commons.
Frequently asked questions
Is 12-hour caching always cheaper?
No. Its write costs 2.5x input against 1.25x for the 30-minute default. It saves money only when a prefix is reused several times more than 30 minutes apart.
Which models support the 12-hour option?
GPT-5.6 and later, through the Responses API. Earlier models use a separate 24-hour retention setting.
Does a cache read restart the 12-hour clock?
No. A read keeps the later expiry; it does not extend a 12-hour entry or add a write charge.
Your next customer could start right here.
Introduce your tool, product or business to readers exploring technology.
Explore placements and request a private quote
Sources
- API changelog: 12-hour prompt caching — OpenAI, 2026-10-20
- Prompt caching guide — OpenAI
- API pricing — OpenAI
Written with substantial AI assistance. Facts checked against cited sources. Editorial policy.
Comments
No comments yet. Be the first to join the conversation.
Leave a comment
Every comment is read by a moderator before it appears. Your email address is never published; it is used only to contact you about this comment.
More from Cloudsoft Zone

Industry updateAI and Automation
WebMCP ecommerce: nearly 100,000 stores become AI-agent ready
WebMCP ecommerce at scale: Cloudflare and Commerce.com enabled agent shopping tools on almost 100,000 storefronts. The architecture and the checkout rule.
By Cloudsoft Zone

Industry updateAI and Automation
AI model containment: lessons from OpenAI’s DNS egress incident
AI model containment lessons from OpenAI: an internal model reached the internet through a DNS resolver misconfiguration. How to design agent sandboxes.
By Cloudsoft Zone

Industry updateAI and Automation
Claude in Google Antigravity: setup, billing and multi-model workflows
Claude in Google Antigravity: how admins enable Opus 5.5 and Sonnet 5.5, how pay-as-you-go billing works, and cross-model review with Gemini subagents.
By Cloudsoft Zone
