If you want to have your website to be available only via secure (HTTPS) connections please follow instruction below.

Windows 2003

You need to enable Require secure channel (SSL) option for /htdocs directory. You can do it in HostPilot control panel > Web/FTP Server > Web Server > Settings and Permissions

Once the option is enabled your web server will reply to non-secure (HTTP) connections with an error message "HTTP Error 403.4 - Forbidden: SSL is required to view this resource". A 403.4 custom error page which includes HTML redirection script from the example below can be used to redirect every non-secure connection to HTTPS URL. An example of a simple HTML redirect script that you can use is:

    <META HTTP-EQUIV="Content-Type" Content="text/html; charset=Windows-1252">
    <META HTTP-EQUIV="Refresh" CONTENT="0; URL=https://your_domain.com">

Windows 2008

Simply add the code below to system.webServer section of web.config file:

<rule name="HTTP to HTTPS redirect" enabled="true" stopProcessing="true">
   <match url="(.*)" />
       <add input="{HTTPS}" pattern="off" ignoreCase="true" />
   <action type="Redirect" redirectType="Found" url="https://{HTTP_HOST}/{R:1}" />


The following code should be included into the .htaccess file to enable redirection:

RewriteEngine On
RewriteCond %{HTTPS} !on
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}