Redirecting a domain from HTTP to HTTPS

Do you want your website to always be accessed securely via «https»? Then you need to set up a redirect from HTTP to HTTPS. You can find out how to do this in this article.

 


 

Why is a redirect needed?

Unlike HTTP, HTTPS uses an encryption protocol called SSL (short for «Secure Sockets Layer»). This protocol ensures that data is encrypted between the browser and the web server. For this encryption to work, the website needs an SSL certificate, which is installed on the web hosting server.

However, data is only transmitted encrypted if the website is accessed via HTTPS (instead of HTTP). To enforce this, you need to set up a redirect.

 


 

How do I set up a redirect?

You have the following options for setting up the redirect:

  • If you are using a CMS, it is best to set up the redirect directly in the respective system. Follow our instructions for the most common systems (WordPress, TYPO3, Drupal, Joomla!) or consult your CMS documentation.

  • If you are not using a CMS, we recommend setting up the redirect via the « .htaccess » file. Follow the instructions below.

 


 

Setting up a redirect in .htaccess

  1. To do this, log in to the Plesk Control Panel.

  2. Click on «Websites & Domains» > «Dashboard» and then on «Files».

    → You are now in the File Explorer.

  3. Click on «httpdocs» on the left to go to the document root of your website.

  4. Look for the file named « .htaccess ». If no file with this name exists, create one using the «» button.

  5. Edit the file by clicking on it.

  6. Insert the following code and replace https://your-own-domain.ch/ with the desired target URL:
    redirect 301 / https://your-own-domain.ch/
     
  7. Save your settings.

 

→ The redirect has been set up.


Was this article helpful?

mood_bad Dislike 0
mood Like 0
visibility Views: 307
Related articles:



Unable to find what you were looking for?

Our support experts are happy to assist you personally!



CONTACT SUPPORT