
This test demonstrates how the Bypass Cache for Everything rule in Cloudflare works, serving content directly from the origin without caching.
Normally, Cloudflare caches some content at the Edge. With this rule, HTML, CSS, JS, and other files are served directly from the origin without being cached.
Use Cases: Pages with frequently changing dynamic content or pages that must always show up-to-date information.
Benefits: Content is always up-to-date.
Risks: Increased load on the origin server and potentially longer page load times compared to Cache Everything.
# ---- Bypass Cache for Everything ----
location /cdn/dynamic/ {
alias /var/www/cloudflare/application-service/cdn/dynamic/;
index dynamic_test.html;
try_files $uri $uri/ =404;
}
The Bypass Cache for Everything rule is applied in Cloudflare.
All content is fetched directly from the origin without being cached at the Cloudflare Edge. Edge Cache TTL has no effect in this mode; however, the Browser TTL can be set in the Cloudflare dashboard to control cache directives sent to browsers — content is still not stored at the Edge.
Requests are always fetched from the origin. However, cf-cache-status may not always show BYPASS.
Despite these differences, no content is written to the cache, and every request is served directly from the origin. The bypass rule works correctly.
curl -svo /dev/null 'https://cdn.cloudflares.online/cdn/dynamic/dynamic_test.html' 2>&1 | grep -i 'cf-cache-status:'
curl.exe -s -D - "https://cdn.cloudflares.online/cdn/dynamic/dynamic_test.html" -o NUL | Select-String -Pattern '^CF-Cache-Status:' -CaseSensitive:$false
curl -svo /dev/null 'https://cdn.cloudflares.online/cdn/dynamic/dynamic_test.css' 2>&1 | grep -i 'cf-cache-status:'
curl.exe -s -D - "https://cdn.cloudflares.online/cdn/dynamic/dynamic_test.css" -o NUL | Select-String -Pattern '^CF-Cache-Status:' -CaseSensitive:$false
curl -svo /dev/null 'https://cdn.cloudflares.online/cdn/dynamic/dynamic_test.js' 2>&1 | grep -i 'cf-cache-status:'
curl.exe -s -D - "https://cdn.cloudflares.online/cdn/dynamic/dynamic_test.js" -o NUL | Select-String -Pattern '^CF-Cache-Status:' -CaseSensitive:$false
curl -svo /dev/null 'https://cdn.cloudflares.online/cdn/dynamic/dynamic_api_response.json' 2>&1 | grep -i 'cf-cache-status:'
curl.exe -s -D - "https://cdn.cloudflares.online/cdn/dynamic/dynamic_api_response.json" -o NUL | Select-String -Pattern '^CF-Cache-Status:' -CaseSensitive:$false
curl -svo /dev/null 'https://cdn.cloudflares.online/cdn/dynamic/image.png' 2>&1 | grep -i 'cf-cache-status:'
curl.exe -s -D - "https://cdn.cloudflares.online/cdn/dynamic/image.png" -o NUL | Select-String -Pattern '^CF-Cache-Status:' -CaseSensitive:$false
BYPASS → Content not cached, request served directly from origin (seen in special cases).
DYNAMIC → Dynamic content, never cached by Cloudflare.
MISS → Static content not present in cache, fetched from origin (not written to cache in this mode).
In Bypass Cache for Everything, Cloudflare Cache Rules ensure content is served without caching. Important settings:
Loading...
Watch this short demo to observe CDN in action.