-1

Redirect https alias to http main domain (it is showing no private connection error)

I have one domain alias www.domain2.example The main domain is www.domain1.example

When someone enters to www.domain2.example it shows "SSL connection is no private NET::ERR_CERT_COMMON_NAME_INVALID"

I need that the user is redirected from www.domain2.example to www.domain1.example

I have tried a lot of ways using https and none works

3
  • 2
    You need to install an SSL cert that covers your domain alias. (And your main domain?) However, it doesn't make sense to redirect from HTTPS to HTTP. Why do you want to do this? – MrWhite May 7 '20 at 21:53
  • Like @MrWhite says...why would you want to do this when the web is moving towards https and http sites are penalised in search engines. – Steve May 7 '20 at 22:01
  • This other question is asking the same... webmasters.stackexchange.com/questions/127368/… - there must be a good canonical Q that already covers this? – MrWhite May 7 '20 at 22:04
1

The requirement for an SSL certificate is determined by the domain you're redirecting from, as that's the domain that will be serving up the redirect itself.

In short, the server behind your "from" domain needs to have a valid SSL certificate to serve up a redirect from https. If you're using a "redirecting service" like the "domain forwarding" option provided by many registrars, it likely won't allow you to attach an SSL certificate, so it's likely that you'll need to connect your domain to a real hosting service to get this working.

I did write an article about using Google App Engine to do free redirects over https, but the article is admittedly a bit out of date now.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.