How to redirect www URLs to non-www?

You can redirect all of the requests for www.yourdomain.com domain to yourdomain.com by modifying your website's .htaccess file. You have to add the following lines in the beginning of the file so that the redirection is properly set up:

You should replace yourdomain.com with your actual domain name.

You can edit the .htaccess file using the File Manager in cPanel or via FTP.

From now on, when someone access http://www.yourdomain.com that visitor will be redirected to http://yourdomain.com.

You find this article useful? Click here to learn more about SiteGround web hosting experts and what else we can do for you!