Site5 - Built For Designers & Developers MENU
Home  ›  www

Apache: How to set your domain to redirect to WWW by default

Add the below to your .htaccess file in order to have your-domain redirect to www.your-domain. Just make sure where it says “your-domain.com” to fill in your domain on both lines 2 and 3. RewriteEngine on RewriteCond %{HTTP_HOST} !^www.you-domain.com$ RewriteRule ^(.*)$ http://www.your-domain.com/$1 [R=301] Why would you do this? It makes your […]

Money Back Guarantees
Click to verify BBB accreditation and to see a BBB report.