{"name":"ENABLE_PROMPT_CACHING_1H","slug":"enable-prompt-caching-1h","family":"env","title":"Environment variables","noun":"environment variable","description":"You can pin the prompt cache to five minutes or an hour, separately for subagents.","description_source":"entry","described_by":{"version":"2.1.242","anchor":"prompt-cache-lifetime-is-now-configurable"},"presence":{"first_seen":"2.1.138","removed_in":null,"in_current_build":true,"newest_mined":"2.1.308","builds":149,"mined_builds":149,"first_cited":null},"aliases":[],"entries":[{"version":"2.1.242","anchor":"prompt-cache-lifetime-is-now-configurable","heading":"Prompt cache lifetime is now configurable","line":"You can pin the prompt cache to five minutes or an hour, separately for subagents.","released_at":"2026-08-24 19:16:14","reason":"found in this entry's text"}],"entries_total":1,"docs":[{"source":"claude-code","path":"agent-sdk\/cost-tracking","title":"Track cost and usage","documented":false},{"source":"claude-code","path":"amazon-bedrock","title":"Claude Code on Amazon Bedrock","documented":false},{"source":"claude-code","path":"claude-platform-on-aws","title":"Claude Code on Claude Platform on AWS","documented":false},{"source":"claude-code","path":"google-vertex-ai","title":"Claude Code on Google Cloud's Agent Platform","documented":false},{"source":"claude-code","path":"microsoft-foundry","title":"Claude Code on Microsoft Foundry","documented":false},{"source":"claude-code","path":"prompt-caching","title":"How Claude Code uses prompt caching","documented":false},{"source":"claude-code","path":"settings-reference","title":"All settings","documented":false},{"source":"claude-code","path":"whats-new\/2026-w16","title":"Week 16 \u00b7 April 13\u201317, 2026","documented":false}],"docs_total":8,"gates":[],"related":[{"name":"ENABLE_PROMPT_CACHING_1H_BEDROCK","slug":"enable-prompt-caching-1h-bedrock","description":"When `1`, `true`, `yes` or `on` and the API provider is Bedrock, requests use a `1h` prompt cache TTL. It applies only when no earlier source decides the TTL: `FORCE_PROMPT_CACHING_5M`, the `CLAUDE_CODE_PROMPT_CACHE_TTL` or `CLAUDE_CODE_SUBAGENT_PROMPT_CACHE_TTL` env vars, the `promptCacheTtl` or `subagentPromptCacheTtl` settings, and an agent's frontmatter TTL all take precedence. `ENABLE_PROMPT_CACHING_1H` does the same for every provider."}],"url":"https:\/\/changelogs.core-directive.com\/reference\/env\/enable-prompt-caching-1h","family_url":"https:\/\/changelogs.core-directive.com\/reference\/env.json"}