Redirect root domain to www. domain

When setting up your CNAME to point to Kickpages you are basically telling the DNS servers to serve the website hosted at Kickpages when the www. version of your domain is visited. 

www is basically only a subdomain of the main domain name, so anyone visiting http://www.mydomain.com will receive the page hosted at Kickpages but everyone visiting http://kickpages.com will receive a basic page from your domain provider or hosting provider. To serve the correct page which you have created in Kickpages, you have to redirect the non-www version of the domain name to the www version. You can do this easily by following the guides below, if your provider is not covered and not sure what to do, then please let us know.

If your domain pints to a server:
If your domain name is pointing to hosting (not required) then this means that every versions of your domain already point to your server, then we need to make a redirect on your server to force everyone to the www version of the domain name. You can do this by adding a or editing an existing .htaccess file in the root of your domain name. This can be, a folder called "www" or "public_html" or anythign else, please consult your hosting company if not sure. You can use your favorite FTP client or your server panels file manager like cPanel's file manager to make these changes. Please note, that in case of cPanel, you might need to allow showing of "Dot files" .htaccess being such a file. You can do that by clicking on settings in the top right corner of cPanel's file manager and selecting the option to show the dot files.

Create or edit if exists the .htaccess file with the content below:

RewriteCond %{HTTP_HOST} !^www\. [NC,OR]
RewriteCond %{HTTPS} off
RewriteCond %{HTTP_HOST} ^(?:www\.)?(.+)$ [NC]
RewriteRule ^ https://www.%1%{REQUEST_URI} [R=301,L,NE]

If you already have the .htaccess file and it has content, you can just add it above the existing content. What it does, is that automatically seamlessly redirects all traffic to the www version of the domain, indifferent if the visitor is on the root domain or a sub page.

If your domain is NOT pointing to a server:

When you purchase a domain name, does not automatically points to your server if you own one, you have to set up the name servers in order to tell the DNS servers where to look for your website files when someone visits your domain name. In order to redirect non WWW traffic to WWW you do not need to have a server. In this case, you can add a redirect to your domain name at your domain provider, this will force all visitors to the www version of your website.

Godaddy:

Go yo your domains and click the three small dots to manage it, then select DNS setting (this is where you have added the Kickpages CNAME to your domain), scroll down and you will see the Forwarding option. Make sure that you select "https://" and enter your domain name in the field by adding "www." in the front of it. Make sure that "Permanent" and "Forward only" is selected and click on "Save"

Namecheap:

With Namecheap you can click on "Manage" besides your domain name and scroll down, make sure that you have the "Nameservers" field set to "Namecheap BasicDNS", if it is pointing to your custom nameservers and you would like to keep it like that, then please use the .htaccess method above.

At "Redirect Domain" click on "ADD REDIRECT" and enter your domain twice, first without any protocol (http:// or https://) and without "www." then the second time by adding "https://www." in front of your domain name, click on the small check mark to save your changes.

Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Create a support ticket Create a support ticket