skip to Main Content

I am using ‪CentOS Linux 7.3.1611 with Plesk Onyx 17.0.17 to forward (301) myolddomain.com to mynewdomain.com. mynewdomain.com has a valid SSL certificate.

However, if I go to https://myolddomain.com, then I get a certificate error and the domain does not get forwarded. How do I make https://myolddomain.com forward too. Do I need to host my old domain and use .htaccess to make the redirect? I don´t want to leave it as it is because that means having duplicate content and that´s obviously bad for SEO.

EDIT

The forwarding works fine for all non https requests.

2

Answers


  1. You need to have a server at the old domain, and it has to have a valid certificate for the old domain name, in order to provide a redirect under https.

    This is because of how https works. First the secure connection must be established, which requires the certificate. Only then can the http request and the redirect response be made.

    Login or Signup to reply.
  2. This free service will forward the old domain to the new one…

    https://redirect.pizza/

    Once you set up the account there, you then need to update your A record and CNAME record in the DNS for the old domain to point to the redirect.pizza servers.

    They use LetsEncrypt to generate the certificate for the old domain. I have been using it and it works perfectly.

    Note that doing this could potentially let redirect.pizza put up anything they wanted on your old domain rather than forwarding to new domain, so you have to trust them. If you are worried about this, you could monitor the old domain and if they ever stop forwarding, then you could defensively update you DNS to no longer point to them.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search