.htaccess Redirect Generator

.htaccess Redirect Generator is a free tool used to generates htaccess redirect. Using .htaccess we can redirect www to non-www Urls or redirect non-www to www Urls or redirect old domain requests to new domain, redirect to mobile version, etc....

1. Select redirect type

Redirect www to non-www

Redirect non-www to www

2. Enter your domain name

Do not include www. Domain name only - e.g. yourdomain.com

3. Get your code

4. Copy the code to your .htaccess file

What is .htaccess file?

.htaccess Rewrite Generator uses to search engine friendly 301 redirects, and redirects mobie version, redirect old page to new page, old website to new website, old domain to new domain, https to http, etc..

Enter your domain name then click the "Get .htaccess Code" button. Copy the resulting code from the box below to your .htaccess file on your website then click F5 button on keybroad or refresh your webpage.

e.g. your-domain.com/blog/web-page.html to www.your-domain.com/blog/web-page.html