301 Redirect Generator

Create 301 redirect rules for Apache .htaccess or Nginx from a list of old paths and new addresses.

Redirect rules

In short

What is the 301 Redirect Generator?

The 301 redirect generator turns lines of old path and new address into permanent redirect rules for Apache .htaccess or Nginx. Paste the rules into your server configuration and test each one. A 301 tells browsers and search engines a page has moved for good, helping keep visitors and signals on the right page.

How to use it

  1. List redirects as old path | new address, one per line.
  2. Choose Apache .htaccess or Nginx.
  3. Copy the generated rules.
  4. Add them to your server configuration and test every old address.
Questions

301 Redirect Generator — FAQ

When should I use a 301?

When a page has moved permanently, such as after changing a slug or merging pages. Use a temporary redirect for short-term moves.

Where do the Nginx rules go?

Inside the relevant server block of your Nginx configuration, followed by a configuration reload.

Should I redirect to the home page by default?

Send each old page to the closest relevant new page. Mass redirects to the home page are usually unhelpful.

More SEO, AEO & GEO tools