Domain forwarding - Namecheap's https problem

293 Views Asked by At

I own a domain, let's call it abcdef.com, which is registered through Namecheap. I intend to use this domain primarily for sharing educational videos via the Thinkific platform. To better structure my services, I've decided to offer these educational videos through a subdomain: education.abcdef.com. This will allow me to utilize the main domain for other purposes in the future.

Currently, I don't have a specific use for the main domain. Therefore, I'd like to set up automatic redirects so that all traffic going to abcdef.com or www.abcdef.com is directed to education.abcdef.com.

Setting up a basic redirect is straightforward with Namecheap, but there's a hitch: Namecheap's redirect servers don't support SSL certificates. Given that modern browsers are increasingly enforcing HTTPS by default, this is problematic. When someone types abcdef.com into their browser, the automatic conversion to https://abcdef.com occurs, but the redirect fails since no SSL certificate is installed. However, if the "http" prefix is manually entered (i.e., http://abcdef.com), the redirect works as expected.

I've considered using Netlify for this, but I found its settings somewhat confusing.

Do any of you have ideas on how to set up a seamless redirect that functions regardless of whether a visitor's browser is set to HTTP or HTTPS?

For your information, the only DNS record (which is CNAME record) I currently have is for education.abcdef.com, pointing to my Thinkific website. This record is essential and needs to be retained, although I'm open to adding other DNS records if necessary.

Thank you in advance for your help!

Tried: Namecheap's forward services - don't work. Tried Netlify, but was lost a bit. Expecting: seamless redirect that functions regardless of whether a visitor's browser is set to HTTP or HTTPS

1

There are 1 best solutions below

2
cnavar On

I suggest that you setup a redirect using .htaccess file.

  1. Go to public_html folder. Look for .htaccess file, right-click >> Edit and add the code below after the line RewriteEngine On

RewriteCond %{HTTP_HOST} ^abcdef.com [NC]

RewriteRule ^(.*)$ http://www.abcdef.com/$1 [L,R=301]

Note: If you can't locate the .htaccess, check if the Hidden files is enabled > click Settings > Show Hidden files (dotfiles) shoud be checked.

  1. Here's the steps on how you can access the .htaccess file from your Namecheap account or how you can create a new one:

source: https://www.namecheap.com/support/knowledgebase/article.aspx/9410/29/how-to-set-up-rules-and-redirects-in-htaccess/#redirect

  1. Don’t forget to replace abcdef.com with your actual domain name. Once you’re done, make sure to save the changes.

I hope this works for you!