Skip to Content
Advanced FeaturesCaching Control

Caching Control

APXY can strip cache-related headers (Cache-Control, ETag, If-None-Match, If-Modified-Since, etc.) from requests and responses to force the server to return fresh data.

Web UI

Caching control is managed from the CLI. The Web UI does not have a dedicated caching page.

CLI

Disable caching

# Disable caching for all traffic apxy caching disable-cache # Disable caching for a specific host apxy caching disable-cache --host api.example.com
FlagDefaultDescription
--host(all)Apply to a specific host only

Re-enable caching

apxy caching enable-cache

Use Cases

Debug stale data

When you suspect a cache is serving old data:

apxy caching disable-cache --host api.example.com # Reproduce the issue — if it resolves, the cache was the problem apxy caching enable-cache

Force fresh responses during development

Ensure you always see the latest API responses while developing:

apxy caching disable-cache # Develop and test with guaranteed fresh data apxy caching enable-cache
Last updated on