.htaccess Redirect Generator

Simple SEO Tools to Improve Your Website’s Ranking

Htaccess Redirect Generator


1. Select redirect type





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



About Htaccess Redirect Generator

The .htaccess Redirect Generator allows you to quickly generate the necessary code for redirecting between the "www" version and "non-www" version of your domain. Whether you need to redirect from www to non-www or vice versa, this tool provides the code to add to your .htaccess file.

How It Works

  1. Select Redirect Type – Choose whether to redirect from www to non-www or non-www to www.
  2. Enter Domain – Input your domain name to customize the redirect code.
  3. Get .htaccess Code – The tool will generate the necessary redirect code for you to copy.
  4. Add to .htaccess – Paste the generated code into your .htaccess file to activate the redirect.

Why Use This Tool?

  • SEO Optimization – Ensure your website uses a single canonical URL format, which is essential for SEO.
  • Easy to Use – Generate the required .htaccess code with just a few clicks.
  • Prevent Duplicate Content – Set up the redirect to avoid search engines indexing both the www and non-www versions of your site.

Use the .htaccess Redirect Generator today to set up redirects and optimize your website’s URL structure!