Allowing only TLS connections to your site

If you want to only allow TLS on your site, we have you covered. There is a switch built into the "Request Settings" that will allow you to force unencrypted requests over 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 http://www.example.com/foo.jpeg would redirect to https://www.example.com/foo.jpeg.

  1. Log in to the Fastly application and click the configure button (wrench icon).
  2. From the Service menu, select the appropriate service and then click the blue Configure button (with the gear icon) to the right of the service name.
  3. Click the Settings pane and find the Request Settings section.
  4. Click the New button to the right of the Request Settings section. The New Request Settings window appears.

    the New Request Settings window

  5. Type a name in the Name field. ('Default' works fine, if it's your only one.)

  6. Select Yes from the Force SSL menu.

  7. Click Create to save your request setting changes.

Once you deploy your changes, you're done!

For more information about TLS-related issues, see our TLS guides or contact support@fastly.com with questions.

Back to Top