> For the complete documentation index, see [llms.txt](https://clients.medianova.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://clients.medianova.com/products/performance-cdn/dynamic-content-acceleration/advanced-configuration/caching/header-value-base-cache.md).

# Header Value Base Cache

The **Header Value Base Cache** feature allows you to **explicitly allow or deny caching when a request contains a specific HTTP header value**.\
This provides precise control over caching behavior for **Dynamic Content Acceleration** resources where certain header values determine whether content should be cached.

{% hint style="info" %}
This feature is available **only for Dynamic CDN Resources**.
{% endhint %}

## How Header Value Base Cache Works

When **Header Value Base Cache** is enabled:

* Medianova CDN inspects incoming requests for the configured **Header** and **Value**.
* If the request matches the defined rule:
  * **Allow** — the response is eligible for caching.
  * **Deny** — the response bypasses the cache and is fetched from the origin.
* Requests that do not match the rule follow the default caching behavior.

This mechanism allows cache decisions to be enforced **conditionally**, rather than only by cache key variation.

## Configure Header Value Base Cache

You can configure this feature from the [**Medianova Control Panel**](https://cloud.medianova.com).

{% stepper %}
{% step %}
**Open the Caching Settings**

Log in to the **Medianova Control Panel**, navigate to **CDN → CDN Resources**, select a **Dynamic CDN Resource**, and open the **Caching** tab.

<figure><img src="/files/5pY3O5y2JduArD85Csdp" alt="" width="563"><figcaption></figcaption></figure>
{% endstep %}

{% step %}
**Enable Header Value Base Cache**

Set **Status** to **On**.
{% endstep %}

{% step %}
**Select the Rule Type**

Choose the behavior for matching requests:

* **Allow** — matching requests are cached
* **Deny** — matching requests bypass the cache
  {% endstep %}

{% step %}
**Define the Header Rule**

Enter the rule parameters:

* **Header** — Name of the HTTP request header
* **Value** — Header value to match
  {% endstep %}

{% step %}
**Apply the Configuration**

Select **Submit** to save and apply the changes.
{% endstep %}
{% endstepper %}

* Only **one header value-based rule** can be active at a time.
* Header matching is **exact**; both header name and value must match.
* This feature controls **cache eligibility**, not cache key variation.
* Can be combined with **Header Base Cache** and **Cookie Base Cache** for advanced caching strategies.
* Incorrect use of **Deny** may significantly reduce cache hit ratio.

## Common Use Cases

* Prevent caching when a request contains a debug or preview header
* Allow caching only when a specific feature-flag header is present
* Enforce cache bypass for internal or authenticated traffic
* Control caching behavior based on application-specific headers


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://clients.medianova.com/products/performance-cdn/dynamic-content-acceleration/advanced-configuration/caching/header-value-base-cache.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
