How Google reads a 302 Found
MDN notes that browsers follow a 302 to the URL in the Location header automatically. Google's crawlers follow a 302 by default, but Google treats it only as a weak signal that the target should be processed. For Google Search, a temporary redirect is not used as a signal that the target should be canonical. Google may still index the target of a 302 if other canonicalization signals point to it. Google says a temporary redirect may help keep the old URL in its search results.
A 301 works the other way. Google reads a permanent redirect as a signal that the target URL should become the canonical URL.
302 vs 307 and 303, caching and setup
HTTP/1.0 (RFC 1945) named status 302 "Moved Temporarily" and defined it as method-preserving, but already noted that some user agents wrongly changed a redirected POST into a GET. Browsers in practice converged on switching the method to GET when following a 302, and RFC 9110 now lets a client change a POST into a GET for historical reasons. If the method must stay the same, RFC 9110 points to 307 Temporary Redirect instead of 302.
Google's grouping. Google Search lists 302, 303 and 307 together as temporary redirect types.
Caching. 302 is not in RFC 9110's list of heuristically cacheable codes, so a cache reuses it only when the response carries explicit cache controls.
Typical use. Google's example is a temporarily unavailable service, with users sent to a page that explains the situation.
Apache. mod_alias sets a temporary redirect with
Redirect temp.
Use a 302 only while you plan to bring the original URL back. For full moves, see how long a website migration takes; for redirects in Next.js, see the Next.js SEO guide.
Sources
- RFC 9110: HTTP SemanticsIETF · rfc-editor.org
- 302 Found - HTTP | MDNMozilla (MDN) · developer.mozilla.org
- How HTTP status codes, and network and DNS errors affect Google SearchGoogle · developers.google.com
- Redirects and Google SearchGoogle · developers.google.com
- RFC 1945: Hypertext Transfer Protocol -- HTTP/1.0IETF · rfc-editor.org