Htaccess Redirect Generator

Generate a simple 301 redirect rule.

  • Free
  • No sign-up
  • Instant results

1 Your input

2 Result

Your result will appear here

Fill in the form and press the button. Results show up right here, without reloading the page.

How to use Htaccess Redirect Generator

  1. Enter the old pathType the path that should redirect in From path, for example /old-page.
  2. Add the destination URLEnter the full target address, including https://, in To URL.
  3. Copy the Redirect linePress Run Htaccess Redirect Generator and paste the generated line into the .htaccess file in your site root.

Common uses

  • Point a deleted page to its replacement
  • Send an old blog post to a new domain
  • Add a quick redirect without writing mod_rewrite rules

Frequently asked questions

How do I use Htaccess Redirect Generator?

1. Enter the old path: Type the path that should redirect in From path, for example /old-page. 2. Add the destination URL: Enter the full target address, including https://, in To URL. 3. Copy the Redirect line: Press Run Htaccess Redirect Generator and paste the generated line into the .htaccess file in your site root.

What syntax does it produce?

A single mod_alias line such as Redirect 301 /old-page https://example.com/new-page. Choose 301 for a permanent move or 302 for a temporary one under Redirect type. Paths with spaces are quoted.

Will pages below the old path be redirected too?

Yes, that is how Redirect works on Apache: it matches the path as a prefix, so /old-page/extra goes to the target with /extra appended. Use the URL Rewriting Tool or RedirectMatch if you only want an exact match.

Does it check that the redirect works?

No. It only writes the line and never contacts your server. The rule needs Apache with .htaccess overrides allowed, and Nginx ignores it, so test the old address after uploading.

What happens to the paths I enter?

They are sent to the GigaTools server, inserted into the Redirect line and returned. Your site is not contacted and the tool does not save the values.