One minute
Clearing an end user’s cached 301 redirect
tl;dr if they’re not using Firefox you can send them a Clear-Site-Data: “cache” header from the same origin.
e.g. in PHP, send them a header
header('Clear-Site-Data: "cache"');
This can be on its own standalone URL, e.g. https://example.com/clear-cache.php – it clears cache for the origin, in this case example.com.
Source:
https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Clear-Site-Data
Firefox
Firefox doesn’t support this header yet.
Open Dev tools, turn caching off, visit the cached redirect URL again, cache should be cleared.
73 Words
2023-04-21 13:23