Redirect HTTP to HTTPS for all pages on Adobe Commerce on cloud infrastructure (Force TLS)

Activate the Fastly’s Force TLS functionality in the Commerce Admin to enable the global HTTP to HTTPS redirect for all pages of your Adobe Commerce on cloud infrastructure store.

This article provides detailed steps, a quick overview of the Force TLS feature, affected versions, and links to related documentation.

Steps steps

Step 1: Configure Secure URLs step-1-configure-secure-urls

In this step, we define the secure URLs for the store. If that’s already done, go to Step 2: Enable Force TLS.

  1. Log in to the Commerce Admin.
  2. Navigate to Stores > Configuration > General > Web.
  3. Expand the Base URLs (Secure) section. magento-admin_base-urls-secure.png
  4. In the Secure Base URL field, specify the HTTPS URL of your store.
  5. Set the Use Secure URLs on Storefront and the Use Secure URLs on Admin settings to Yes. magento-admin_base-urls-secure-settings.png
  6. Click Save config in the upper-right corner to apply changes.

Related documentation in our user guide: Store URLs.

Step 2: Enable Force TLS step-2-enable-force-tls

  1. In the Commerce Admin, navigate to Stores > Configuration > Advanced > System.
  2. Expand the Full Page Cache section, then Fastly Configuration, then Advanced Configuration.
  3. Click the Force TLS button. magento-admin_force-tls-button.png
  4. In the dialog that appears, click Upload. magento-admin_force-tls-confirmation-dialog.png
  5. After the dialog closes, make sure the current state of Force TLS is displayed as enabled. magento-admin_force-tls-enabled.png

Related Fastly documentation: Force TLS guide for Adobe Commerce 2.

About Force TLS

TLS (Transport Layer Security) is a protocol for secure HTTP connections that replaces its less secure predecessor—the SSL (Secure Socket Layer) protocol.

The Fastly’s Force TLS functionality allows you to force all incoming unencrypted requests for your site pages to TLS.

It works by returning a 301 Moved Permanently response to any unencrypted request, which redirects to the TLS equivalent. For instance, making a request for would redirect to

Securing communications (Fastly documentation)

Affected versions

  • Adobe Commerce on cloud infrastructure:

    • version: 2.1.4 and later
    • plans: Adobe Commerce on cloud infrastructure Starter plan architecture and Adobe Commerce on cloud infrastructure Pro plan architecture (including Pro Legacy)
  • Fastly: 1.2.4

No changes needed in routes.yaml

To enable HTTP to HTTPS redirect on all pages of your store, you do not have to add the pages to the routes.yaml configuration file—enabling Force TLS globally for your entire store (using the Commerce Admin) is enough.