How it works
Claude: you mark where the fixed part of the prompt ends. The first call writes it to cache (1.25× the input price, or 2× for a 1-hour TTL); later calls read it for a fraction of the price: 2.5% to 10% of input, depending on the model. The cache expires after 5 minutes unused (or 1 hour).
OpenAI: on GPT-5.6 and GPT-6 models, cache writes cost 1.25× input and cache reads 10% of input (5% on GPT-6.1 Sol). The prefix must be at least 1,024 tokens.
Below each model's minimum (4,096 tokens on Claude Haiku 4.5, 512 on Claude 5.x, 1,024 on GPT-5.6 and GPT-6) the prompt isn't cached and the calculator uses the normal price.
When it pays off
When the fixed part is large and calls come often enough that the cache doesn't expire. With a low hit rate, each write costs more than the reads save.
Put what never changes (instructions, tools, documents) at the start of the prompt and what changes per call at the end.