Watch: Cut Claude costs with prompt caching | Vovy

Watch Vovy do it on a Mac: "Turn on prompt caching so I stop paying full price for the same long prompt". Mark the long, repeated part of your Claude prompts as cacheable so repeat requests cost a fraction and respond faster.

"Turn on prompt caching so I stop paying full price for the same long prompt"

Mark the long, repeated part of your Claude prompts as cacheable so repeat requests cost a fraction and respond faster.

What happens in the video

  1. Find repeated prompt content: Vovy asks Claude Code to find prompts that resend the same big block every time, like a long system prompt, docs, or tool definitions.
  2. Reorder for caching: Caching works on the start of a prompt. Claude Code moves the stable content first and the changing user message last.
  3. Add cache_control: Claude Code adds a cache_control breakpoint after the stable block in your Claude API call, so Anthropic reuses it on the next request.
  4. Check OpenAI calls too: OpenAI caches long repeated prefixes automatically. Vovy checks your OpenAI prompts follow the same stable-first order to benefit.
  5. Measure cache hits: Vovy sends two identical requests and shows the usage fields for cache reads versus normal input tokens, with the cost difference on a card.
Read the step-by-step guide