> 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/security/ssl-tls-encryption/always-use-https.md).

# Always Use HTTPS

**Always Use HTTPS** automatically redirects HTTP requests to HTTPS, ensuring that visitors use encrypted connections when accessing your content.

You can manage Always Use HTTPS in the [Medianova Control Panel](https://cloud.medianova.com).

Navigate to the relevant CDN Resource and open the **Security** section.

## Configure Always Use HTTPS

{% stepper %}
{% step %}

### Enable Always Use HTTPS

Toggle **Status** to **On**.

<figure><img src="/files/7SF0JsnUWR7Jq3TnDHwL" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Select the Redirect Code

Choose the HTTPS redirect status code:

* **301** — Permanent Redirect
* **302** — Temporary Redirect
  {% endstep %}

{% step %}

### Save the Configuration

Click **Submit** to apply the configuration.
{% endstep %}
{% endstepper %}

### Behaviour

* All HTTP requests are redirected to the HTTPS version of the same URL.
* Query strings and request paths are preserved during the redirect.
* HTTPS requests are not affected.
* A valid SSL certificate must be configured for HTTPS delivery.

### Redirect Codes

Select the redirect status code used when HTTP requests are redirected to HTTPS.

* **301 (Permanent Redirect)** — Recommended for production environments and SEO.
* **302 (Temporary Redirect)** — Use when HTTPS enforcement may change in the future.

For detailed information about [HTTP Response Codes](/getting-started/concepts/http-response-codes.md)

### FAQ

**Should I use 301 or 302?**\
For most production environments, 301 is recommended.

**Does this affect existing HTTPS requests?**\
No. Only HTTP requests are redirected.

**What happens if HTTPS is not configured correctly?**\
Clients may receive SSL/TLS errors after being redirected.

**Does this improve security?**\
Yes. It helps ensure traffic is delivered over encrypted HTTPS connections.


---

# 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/security/ssl-tls-encryption/always-use-https.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.
