DevKits
302

Found

3xx Redirection

Last updated:

The resource is temporarily at a different URL. The client should continue to use the original URL for future requests.

Description

Historically ambiguous about method preservation, which is why 307 and 308 were introduced. In practice, most clients treat 302 as 'redirect via GET', so 307 is preferred when the method must be preserved.

When to use

Use 302 for temporary redirects such as post-login redirects or A/B testing routes.

Also searched as

Developers commonly search for 302 using phrases like 302 redirect · 302 found · 302 vs 301 · 302 temporary redirect · http 302 · 302 status code. All refer to the same HTTP 302 Found response.

Specification

RFC 9110 §15.4.3

Examples

HTTP response
HTTP/1.1 302 Found
Content-Type: application/json

Location: /new-url
Node.js (Express)
res.status(302).redirect("/new-url");
Go (net/http)
w.WriteHeader(http.StatusFound)
Python (Flask)
return jsonify({"error": "Found"}), 302

Debug 302 with these tools

Related status codes

All 3xx codes