CloudFlare can only accelerate and protect CNAMES. Since your root domain is an A record, we recommend that you forward your traffic to ‘www’ through your .htaccess file. If you do not forward the traffic, then any traffic to www.mydomain.com will be accelerated and protected by CloudFlare (and shown in the statistics) and any traffic to mydomain.com will not be served by CloudFlare.

Since we work through CNAMEs CloudFlare can not be enabled on the root domain (since it is an A record). So, if you want to protect traffic going to the root domain, then they will need to add a redirect in the .htaccess file to 'www'.

Below is a snippet of code that can be used in your accounts .htaccess file. This snippet of code will direct all traffic from mysite.com to www.mysite.com. Just replace the "mysite.com" and "http://www.mysite.com" with your own domain name.

RewriteEngine On
# Rewrite added for CloudflareInstall - mysite.com
# Wednesday 25th of August 2010 04:59:42 AM
RewriteCond %{HTTP_HOST} ^mysite.com$ [NC]
RewriteCond %{SERVER_PORT} ^80$
RewriteRule ^(.*)$ http://www.mysite.com/$1 [R=301,L]

Was this article useful and on point?

Find out more about MonsterMegs entire range of optimized Web Hosting Services and take action today on improving your website Loading Speed, Security, and overall Stability!
Var dette svaret til hjelp? 18 brukere syntes dette svaret var til hjelp (514 Stemmer)