Making www optional in htaccess rule
snippet in htaccess

Making www optional in htaccess rule

user2591

RewriteCond %{HTTP_HOST} ^(?:www\.)?site\.com$