301 Redirect Generator

Moving or renaming pages? Enter each old path and the new location and copy ready-to-use redirect rules for Apache (.htaccess) and Nginx. Redirects keep visitors and link value when URLs change.

How to use this tool

  1. List each old path followed by "->" and the new URL.
  2. Choose 301 for permanent moves or 302 for temporary ones.
  3. Copy the rules for your server and add them to your .htaccess file or Nginx config.
  4. Test a few old URLs to confirm they land on the right page.

Use 301 for permanent moves

A 301 tells search engines the page has moved for good and passes the old page signals to the new URL. Redirect each old page to the most relevant new page, not everything to the home page, and avoid chains of several redirects in a row.

Want to go deeper? Read our guide: On-Page SEO Checklist: 15 Things to Check Before You Publish.

Frequently asked questions

Where do the rules go?

Apache rules go in the .htaccess file in your site root. Nginx rules go inside the server block of your site configuration, followed by a reload.

Can I redirect a whole domain?

This tool handles individual paths. Domain-wide redirects are usually set up in your host control panel or with a rewrite rule.