12-hour prompt caching: OpenAI costs and break-even
OpenAI adds 12-hour prompt caching with higher write pricing. A GPT-6.1 Sol cost example shows when longer reuse offsets the premium over the 30-minute default.
OpenAI introduced 12-hour prompt caching on October 20, giving API developers a longer-lived alternative to the default 30-minute cache. The longer option costs more to write but can reduce input spending when an agent returns to unchanged material hours later. This update matters particularly for shared instructions and reference packs; below, a GPT-6.1 Sol example shows when the extra write cost pays back.
What 12-hour prompt caching changes
The October 20 API changelog announces the new lifetime and a write price of 2.5 times ordinary input. It extends the capabilities covered in our September breakpoint and diagnostics report, whose 30-minute-only description records the earlier release rather than today’s choices.
On supported GPT-5.6-and-later models, select the longer lifetime in the Responses API, as shown in the caching guide:
{
"prompt_cache_options": {
"ttl": "12h"
}
}
Unset lifetime settings retain thirty minutes. A short write costs 1.25 times ordinary input; both lifetime multipliers are total prices. Reads cost the same with either choice.
These minimum lifetimes concern cached-input pricing, not deletion deadlines or guaranteed latency. Treat the change as a billing and reuse choice, then measure its effect on your workload.
The GPT-6.1 Sol prices behind the calculation
The current official API pricing table lists these GPT-6.1 Sol Standard, short-context rates per million tokens:
| Input category | Price |
|---|---|
| Ordinary input | $2.00 |
| Cached input read | $0.10 |
| Thirty-minute cache write | $2.50 |
| Twelve-hour cache write | $5.00 |
The longer write is twice the shorter write, while a read costs the same in both cases. The relevant comparison is therefore the number of writes avoided, not simply whether a larger cache window sounds useful. These figures concern API input billing, not ChatGPT subscription allowances.
Worked example: three runs separated by three hours
Consider an application that submits the same eight-thousand-token reference prefix three times: once in the morning, again three hours later, and once more after another three hours. This is an original cost illustration, not a measured API benchmark.
Assume each prefix matches an eligible cache boundary. For the shorter-lifetime scenario, assume coverage has expired before each later request; for the longer-lifetime scenario, assume the later requests receive cached-input pricing. Exclude changing user questions, outputs, tools with separate charges, and any other billable work from both totals.
A thirty-minute write of that prefix costs two cents: eight thousand divided by one million, multiplied by $2.50. Three separate writes therefore cost six cents.
A twelve-hour write costs four cents. Each subsequent full-prefix read costs eight hundredths of a cent. One longer write followed by two reads totals $0.0416, compared with $0.0600 for the three shorter writes. The difference is $0.0184, or about 30.7 percent of the shorter-write total.
There is a second comparison worth making. Processing the same prefix as ordinary input three times would cost $0.0480. In this constructed schedule, the longer-cache total beats that amount by $0.0064. With only two requests, however, one longer write and one read cost $0.0408, above the $0.0320 ordinary-input comparison. A single planned return is not enough to justify this example’s premium against ordinary input.
Those comparisons answer different questions. A team already choosing between cache lifetimes should compare the first pair. A team evaluating its overall input budget should also examine the ordinary-input reference. Keep the number of requests identical across alternatives, and do not count an avoided write as an avoided entire response.
For a larger deployment, multiply the per-prefix difference by the number of independent prefix groups following the same schedule. Do not multiply it by every request indiscriminately: a request using different instructions or reference material does not belong in this illustrative reuse group.
Choose the long-lived prefix deliberately
My recommendation is to start with one genuinely stable reference pack, rather than extending every conversation by default. A frequently changing work queue and a shared policy document have different useful lifetimes. Write down which bytes you expect to remain unchanged before selecting the longer option.
A breakpoint can override the request lifetime, covering the preceding prefix. Overlapping selected writes bill each token once, using the longest applicable lifetime.
This makes placement important. Review the final serialized request, not just the document you intended to cache. If a changing block sits ahead of your shared reference material, moving a setting alone will not produce the stable prefix assumed in the example.
Verify billed reuse before expanding the rollout
Usage separates lifetime-specific writes in usage.input_tokens_details.cache_write_tokens_details, using ttl_30m_tokens and ttl_12h_tokens. The two counts sum to cache_write_tokens; cached_tokens contains reads, not writes.
For your own cost worksheet, use either the two lifetime-specific write components or their aggregate where appropriate, never both as additional charges. Keep request timestamps alongside token counts so you can distinguish frequent reuse from the hours-apart pattern this release targets.
The diagnostics documentation explains how to compare a request with a recent completed response through comparison_response_id. It can identify differences involving tools, input, models, or other cache-sensitive settings. The comparison does not load the earlier conversation or change cache behavior. Actual billing should be checked against response usage, rather than substituting diagnostic token estimates.
Diagnostics carry no additional feature charge, but any extra baseline or retry requests are billed normally. An unavailable comparison is inconclusive. Budget the test requests themselves instead of treating investigation as free inference.
What to check before changing your budget
Run a small, representative trial and compare total input spending across a complete reuse cycle. Include the first write, later reads, changed prefixes, and requests that never return. An apparently excellent read rate can conceal an expensive population of one-time prefixes.
Our existing prompt-caching calculator does not yet model separate twelve-hour or mixed-lifetime writes. Use it for its existing shorter-lifetime assumptions, not as verification of the new example. The pricing guide provides broader context; this dated report does not mean its rates or the tools have already been updated.
The practical decision is narrow: buy a longer pricing window for material you will reuse, and verify the resulting bill. More retention time alone is not a saving.