New researchTechnical SEO & AI Search · 2027Explore the framework

Redirect mapping for a site migration: how to build and test it

How to build a page-to-page redirect map for a migration, which old URLs to include, how to handle pages with no equivalent, and how to test every redirect.

Part of the Site Migrations series. For the full picture, start with Site migration SEO checklist: crawl before, during and after launch.

The redirect map is the single most important document in a migration. Get it right and Google transfers rankings to the new URLs within weeks. Get it wrong, with missing rows, chains or everything sent to the homepage, and the traffic that came from those URLs goes with them.

This guide covers what goes into a redirect map, how to map pages that don’t have a clean equivalent, and how to test every row before and after launch.

What is a redirect map?

A redirect map is a two-column list: every old URL, and the new URL it should permanently redirect to. Google’s guide to site moves with URL changes makes it a step of its own: “Prepare a URL mapping from the current URLs to their corresponding new format.”

It does three jobs: it’s the specification developers implement, the checklist SEOs test against, and the record of what happened to every URL.

Which old URLs go in the map?

More than your current navigation shows. Combine:

Source Why
A full crawl of the old site Every URL your own links reach
Your XML sitemaps Pages listed but possibly not linked
Search Console: pages with impressions or clicks URLs Google shows, including ones your links don’t reach
Analytics: landing pages with sessions URLs people arrive at from any channel
Backlink data and server logs Old URLs other sites still link to, and URLs crawlers still request

In Crawlens, run a full crawl of the old site with Search Console and Analytics connected. The crawl gives you every linked URL; URLs with impressions the crawl did not find and Landing pages with visits the crawl did not find add the ones that matter but aren’t linked, and imported server logs add URLs Googlebot crawls that the crawl did not find. Export the crawl to Excel as the starting list. Keep the crawl itself as your benchmark.

How do you map old URLs to new ones?

Page to page. Each old URL goes to the new page that best matches it. Google is explicit: “Don’t redirect many old URLs to one irrelevant single URL destination, such as the home page of the new site. This can confuse users and might be treated as a soft 404 error.”

Work in this order:

  1. Pattern rules first. If /blog/2021/05/post-name/ becomes /blog/post-name/, one rule maps thousands of URLs. Write it as a pattern, then expand it to rows so every URL can be tested.
  2. Pages with traffic next. Map every URL with clicks or sessions by hand, and check each target makes sense.
  3. The long tail last. Map what you can; decide deliberately about the rest.
Old page Map to
Same content, new URL Its new URL
Merged into another page The page it was merged into
Product discontinued, close replacement exists The replacement product
Product discontinued, no replacement The most specific relevant category, if it genuinely helps the visitor; otherwise 404/410
Page removed with no equivalent No redirect: return 404 or 410
Parameter and tracking variants Their clean equivalent, or nothing if they were never indexed

Letting a page with no equivalent return 404 is fine. Google’s Page indexing help says “404 responses are not necessarily a problem, if the page has been removed without any replacement.” See broken links.

How should the redirects be implemented?

  • Server-side and permanent. Google recommends “HTTP permanent redirects if possible, such as 301 and 308.” Its redirect documentation explains why: for permanent redirects, “the indexing pipeline uses the redirect as a signal that the redirect target should be canonical”; for temporary ones it doesn’t. JavaScript redirects are a last resort.
  • One hop to the final URL. If old URLs already redirect, update those rules too, so nothing chains through the old structure. See redirect chains.
  • Keep them “for as long as possible, generally at least 1 year.”
  • Watch the edge cases: trailing slashes, uppercase letters, http/https and www/non-www variants, query strings. Each can need its own rule or normalisation.

How do you test a redirect map?

Before launch

If the new site runs on staging with the redirects in place, crawl the old URL paths against staging. Otherwise, test a sample of each pattern rule as soon as the redirects are live.

After launch: test every row

Paste or import the old URLs into a Crawlens URL list crawl (it accepts .txt, .csv and .xlsx files). Every row should return a single permanent redirect to its mapped URL, which should return 200 and be indexable. The audit flags the failures:

Check What it catches
Internal pages return 4xx Old URLs with no redirect
Redirect chains (2+ hops) Rules stacked on old rules
Redirect loops Rules that send URLs in circles
Temporary redirects 302/307 where 301/308 is needed
Pages with search traffic return errors Valuable URLs that broke

To check the destination of each redirect against the map, export the crawl to Excel: the URLs sheet has a Redirects to column. Match it against your map in a spreadsheet and look for rows where they differ. Each URL’s Redirects tab in Crawlens shows the full chain for anything that needs a closer look.

After launch: test the new site

Crawl the new site from its homepage too. Internal links should point straight at new URLs, not through the redirects: Internal links point to redirects catches templates that weren’t updated.

Checklist

These are the redirect tasks; the SEO migration checklist puts them in order with everything else a migration needs.

  • Old URL list built from a crawl, sitemaps, Search Console, Analytics, logs and backlinks
  • Every URL with traffic or links mapped by hand
  • Pattern rules written, then expanded so every row can be tested
  • No mass redirects to the homepage; removed pages return 404/410
  • Server-side 301/308, one hop to the final URL
  • Existing redirects updated to point at new final URLs
  • Old URL list crawled after launch: one permanent redirect each, to a 200 indexable page
  • Redirect destinations matched against the map
  • Internal links updated to new URLs
  • Redirects kept for at least a year

Frequently asked questions

What is a redirect map?

A redirect map is a list of every URL on the old site and the URL it should redirect to on the new one. Developers use it to configure server-side redirects, and SEOs use it to test that every old URL lands on the right new page after launch.

Should I redirect old pages to the homepage?

No. Google warns that redirecting many old URLs to one irrelevant destination, such as the homepage, can confuse users and might be treated as a soft 404. Redirect each old URL to its closest equivalent, or let pages with no equivalent return 404 or 410.

Which redirect type should a migration use?

Server-side permanent redirects, 301 or 308. Google uses permanent redirects as a signal that the target should be canonical; temporary redirects such as 302 and 307 don't carry that signal.

How long should I keep migration redirects?

Google recommends keeping them for as long as possible, generally at least one year, so it can transfer signals to the new URLs, including recrawling and reassigning links.

Which old URLs need to be in the redirect map?

Every URL that exists, gets traffic or has links: all URLs from a crawl of the old site, URLs from your XML sitemaps, every page with Search Console clicks or Analytics sessions, and URLs that other sites link to, even if your own site no longer links to them.

· Founder, Crawlens

Dien builds Crawlens, a desktop crawler for technical SEO audits, and writes about the checks it runs: crawling, indexing, rendering and Search Console data.

Audit your own site with Crawlens

Crawl, run 70 checks, and see them next to Search Console and Core Web Vitals data.

Download free for Windows