Redirect non www to www using your domain name
RewriteCond %{HTTP_HOST} ^example.com$ RewriteRule (.*) http://www.example.com/\ [R=301,L]
Or use this for any domain:
RewriteEngine On RewriteCond %{HTTP_HOST} !^www\. RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/\ [R=301,L]
If you have ssl enabled then add this two line for http to https redirect
RewriteCond %{HTTPS} off RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}
comments
The Best Productivity Apps for Entrepreneurs and FreelancersEntrepreneurs and freelancers are often juggling multiple tasks,… Read More
In today’s competitive market, standing out requires more than just a strong message. A 360-degree… Read More
If you’re ready to take control of your organization’s data by setting up a private… Read More
Building a private cloud involves creating a virtualized environment where you can manage, store, and… Read More
In the rapidly evolving landscape of artificial intelligence, Flex AI stands as a transformative force,… Read More
Apple is set to once again make waves in the smartphone market with the iPhone… Read More
This website uses cookies.