Use a 301 when a page has moved for good. Use a 302 when the move is temporary and the original URL will come back. That is the whole rule, and most redirect problems come from ignoring it: a site migration done with 302s, a "temporary" redirect left in place for two years, or a chain of five hops that nobody remembers creating.
This guide explains how search engines treat each status code, when each is the right choice, and how to audit the redirects already on your site.
The status codes at a glance
| Code | Meaning | Typical use | Which URL Google indexes |
|---|---|---|---|
| 301 | Moved permanently | URL changes, migrations, merged content | The destination |
| 308 | Permanent redirect (method preserved) | Same as 301, common on modern frameworks | The destination |
| 302 | Found (temporary) | Short-term promotions, A/B tests, maintenance | Usually the original |
| 307 | Temporary redirect (method preserved) | Same as 302; also shown by browsers for HSTS | Usually the original |
For SEO purposes, 301 and 308 behave the same, and 302 and 307 behave the same. The 307/308 variants only guarantee that the request method (for example POST) is kept, which matters for forms and APIs, not for rankings.
How Google treats 301s
A 301 is a strong signal that the destination should replace the original in the index. Google has confirmed that 3xx redirects of any kind do not lose PageRank, so you are not "leaking" authority just by redirecting. In practice, consolidation still depends on relevance: redirecting a detailed guide to a loosely related page, or to your homepage, often gets treated as a soft 404, and the signals are simply dropped.
After a 301, expect Google to recrawl the old URL, follow the redirect, and swap the destination into results. On a small site this can take days. On a large migration, weeks. Keep the redirects in place for at least a year, and ideally permanently. Links pointing to the old URL keep sending value only as long as the redirect exists.
How Google treats 302s
A 302 tells Google to keep the original URL in the index because it will return. That is exactly what you want for a two-week sale page or a maintenance window.
If a 302 stays in place for a long time, Google may eventually decide it is effectively permanent and start treating it like a 301. You should not rely on that. Using the correct code removes the guesswork and speeds up consolidation.
When to use a 301
- You changed a URL slug. Redirect the old slug to the new one.
- You moved from http to https, or changed domain. Redirect every old URL to its exact new equivalent, page to page, not everything to the homepage.
- You merged two or more thin or overlapping articles into one. Redirect the retired URLs to the combined article. This is one of the most effective ways to fix keyword cannibalisation.
- You deleted a product or service that has a clear replacement. Redirect to the replacement or the closest category.
- You are standardising URLs. Trailing slash vs none, www vs non-www, uppercase vs lowercase.
When to use a 302
- Temporary campaign or seasonal pages where the original will return
- Geo or device-based routing where the original URL must stay canonical
- Short maintenance windows (a 503 status is often the better choice here)
- A/B tests that send part of the traffic to a variant URL
When not to redirect at all
If a page is gone and has no relevant replacement, return a 404 or 410. Redirecting every dead URL to the homepage is a common shortcut, and Google treats most of those as soft 404s anyway. A clean 404 is honest, costs you nothing, and keeps your redirect map meaningful.
Redirect chains and loops
A chain is when URL A redirects to B, which redirects to C. Googlebot follows up to 10 hops, but every hop adds latency for users and delays consolidation. Chains usually build up over successive migrations. Fix them by pointing every old URL straight at the final destination.
A loop is when A redirects to B and B redirects back to A. The page never loads, and both URLs drop out of the index. Loops usually come from conflicting rules, for example a CMS rule adding a trailing slash while a server rule strips it.
How to implement redirects
Apache (.htaccess):
Redirect 301 /old-page https://example.com/new-page
Nginx:
location = /old-page { return 301 https://example.com/new-page; }
WordPress: The Redirection plugin, or the redirect managers built into Rank Math and Yoast Premium.
Next.js and other frameworks: Define redirects in configuration (for example redirects() in next.config.js, where permanent: true returns 308). Keep the list in version control so redirects are never lost in a redeploy.
Whatever the method, redirect on the server. JavaScript and meta-refresh redirects work for Google in many cases, but they are slower and less reliable than a proper HTTP status.
How to audit your existing redirects
- Crawl the site with Screaming Frog or a similar tool and export all 3xx responses. Flag any 302s and ask whether each is really temporary.
- Check for chains and loops using the crawler's redirect chain report.
- Find internal links that point to redirects. Update them to link directly to the final URL. This saves crawl time and is a quick win.
- Check your sitemap. It should list only final destination URLs, never redirecting ones.
- Review Search Console. Under Indexing → Pages, "Page with redirect" lists URLs Google found that redirect. That is expected for old URLs, but none of them should come from your sitemap or current internal links.
- Test a sample manually with
curl -I https://example.com/old-pageto confirm the exact status code and location header.
Redirects during content consolidation
If your blog has several short articles competing for the same query, merging them is often the fastest way to regain rankings. The process is simple: pick the strongest URL (most links, best performance), fold the useful content from the others into it, 301 the retired URLs to it, and update internal links. Done properly, the combined page usually outperforms any of the originals.
Planning a migration or a content clean-up? Our SEO services team builds and tests redirect maps before anything goes live. For the wider checklist, read our technical SEO audit guide.
