301 vs 302 redirects: which one to use

A 301 says “this moved for good”; a 302 says “this is somewhere else for now.” Visitors land in the same place either way. The difference is what Google indexes and what browsers remember.

Pick your situation

Answer two questions and see which code fits, and what would happen with the other one.

Will the old URL ever come back?
Could the old URL receive form posts or API calls (POST, PUT, DELETE)?
301

Moved Permanently

308 is equally fine; some hosts (Vercel, Next.js) default to it.

In Google

The new URL replaces the old one in results; signals consolidate to it.

In browsers

Cached, often for months: visitors who saw it skip your server next time. Hard to undo.

If you pick the other one

A 302 here would work for visitors but leave Google showing a URL that no longer exists.

Side by side

301 Moved Permanently302 Found
Meaning (RFC 9110)Permanent new URL; clients should update linksTemporary; keep using the original URL
Google’s indexShows the target URLUsually keeps the source URL
PageRankPassed to the targetPassed too, per Google, but canonical stays on the source
Browser cacheCached heuristically, often long-termNot cached unless headers allow
POST requestsBrowsers switch to GETBrowsers switch to GET
Method-safe twin308307

Does a 302 hurt SEO?

Not by itself. Google’s own documentation says it treats 302s as a weak signal that the target should be canonical, and that a temporary redirect left in place for a long time can eventually be treated as permanent. The real cost is delay and ambiguity: after a migration done with 302s, Google may keep showing the old URLs for weeks, and your reports show traffic on URLs that no longer exist. For anything permanent, send a 301 or 308 and remove the doubt.

The opposite mistake is quieter but harder to undo. A 301 used for a two-week sale gets cached by every browser that saw it; when the sale ends, returning visitors are still sent to the sale page until their cache expires.

How to check which one a URL uses

Run it through the redirect checker: permanent hops show as orange plates, temporary ones as yellow. Many CMS plugins and frameworks default to 302 or 307, so check rather than assume, especially after a migration where the rules were bulk-imported.

Explaining this to people outside SEO

The table above is enough for a developer, but a product owner deciding whether a URL is “really” gone needs the consequence, not the code. Lead with what visitors and Google will see a month from now, then name the status code last.

Writing the migration memo for people who don’t care about status codes? Plain words first, jargon last; ahaboo’s narrated explainer on why the Moon has phases is a handy model for that tone.

Questions

What is the difference between a 301 and a 302 redirect?

A 301 marks a permanent move: search engines index the new URL and browsers may cache the redirect. A 302 marks a temporary move: search engines usually keep the original URL indexed and browsers ask the server again each time.

Which is better for SEO, 301 or 302?

Whichever matches reality. For permanent moves a 301 (or 308) consolidates signals onto the new URL fastest. For temporary moves a 302 (or 307) keeps the original URL in search results, which is what you want if it is coming back.

Do 302 redirects pass PageRank?

Google has said that all 3xx redirects pass PageRank. The difference is which URL Google chooses as canonical and shows in results.

Can I change a 302 to a 301 later?

Yes, and it is a common fix after migrations. Google will pick up the permanent signal when it recrawls. Going the other way (301 back to 302) is harder because browsers may have cached the 301.

What about 307 and 308?

They are the method-preserving versions: 307 is temporary like 302, 308 is permanent like 301, and neither lets a POST become a GET. For ordinary page views they behave identically to their counterparts.

Sources: RFC 9110 §15.4.2 (301) and §15.4.3 (302); Google Search Central, “Redirects and Google Search”; RFC 9111 §4.2.2 (heuristic caching).