Redirect Rule Generator
Turn a list of old and new addresses into redirect rules, and catch loops and chains.
How it works
- List the redirects as old -> new, one per line.
- Choose Apache or Nginx and the default status code.
- Copy the rules and add them to your server.
About this tool
When you move or rename a page, a 301 redirect sends visitors and search engines to the new address and keeps most of the page's value. Write each redirect as old -> new, and add a status code if it should differ from the default.
The tool creates Apache Redirect lines or Nginx location blocks and checks your list for redirects to themselves, duplicates, loops and chains. Point each old address straight to the final page. Test the rules on a staging site and keep a backup of your .htaccess file.
Questions
When should I use 301 or 302?
Use 301 (or 308) for permanent moves and 302 (or 307) for temporary ones.
Why avoid redirect chains?
Each extra hop slows the page and may lose crawl time. Redirect old addresses straight to the final one.
Where do the Apache rules go?
In the .htaccess file in your site root, above the WordPress rules.