The Vary HTTP header
Many web servers add Vary HTTP headers to content by default. The Vary HTTP header allows applications to vary content based on the type of browser or other client property, which makes it difficult to cache content. As a Best Practices setting, AMD assumes that all content is cacheable and removes the Vary HTTP header by default before caching content.
- Click the Add Behavior button.
- Type "Remove" in the Search available behaviors field to filter the behaviors listed.
- Select the Remove Vary Header behavior, and click the Insert Behavior button.
- Set the Remove Vary Header slider to "Off".
As a result, AMD treats content as uncacheable unless there is a single Vary argument for gzipped delivery. In this case, if the Vary header is used for something other than compression purposes, AMD assumes that the content should not be cached, because it may be specific to the particular type of client.
AMD can only cache the associated object if the Vary header contains only Accept-Encoding, and Gzip is present in the Content-Encoding header.