301 Redirect Generator
Migrating a site is where rankings go to die. Paste your old-to-new URL map and get correct rules for your server, with special characters escaped properly.
Separate the two URLs with ->, a comma, a semicolon, a tab or spaces. Destinations can be relative paths or full URLs.
Use 301 for migrations. Use 302 only when the old URL will genuinely return.
Rules 0 rules
Test before and after
- Back up the original config.A bad rewrite rule can take a site offline instantly.
- Avoid redirect chains.A → B → C should be rewritten as A → C and B → C.
- Watch for loops.Never let a destination also appear as a source.
- Keep them live for at least a year.Signals need time to transfer, and old links keep sending people.
Which status code to use
A 301 tells search engines the move is permanent, so they should transfer ranking signals and swap the indexed URL. A 302 says the original will come back, so the old URL stays indexed — useful for a temporary sale page, wrong for a migration.
307 and 308 behave the same as 302 and 301 but guarantee the HTTP method is not changed from POST to GET. They matter for APIs and form endpoints, rarely for content pages.
Migration order of operations
- Crawl the old site and export every indexed URL, plus your top landing pages from analytics.
- Map each one to its closest new equivalent in a spreadsheet.
- Generate the rules here and deploy them with the new site, not after.
- Spot-check a sample with curl or your browser's network tab — confirm a single hop and a 301.
- Submit the new sitemap and watch Search Console coverage for a few weeks.