April 24, 2018

htaccess: force non www site to a www

Forrest
RewriteEngine On 

RewriteCond %{HTTP_HOST} !^www\.YOURDOMAIN\.COM$ [NC] 

RewriteRule ^(.*)$ http://www.YOURDOMAIN.COM/$1 [R=301,L]
Skip to toolbar