Skip to main content
HTTP/3xx (Redirection)

302 Found

The requested resource resides temporarily under a different URI. Future requests should continue using the original URI.

❓ Why does this happen?

Used for temporary maintenance redirects, landing page AB tests, and authenticated session gateways.

✅ How to fix it

Verify whether the redirect should be temporary or permanent (301) for SEO indexing.

Return or handle 302 in your stack

// app/old-path/route.ts
export function GET(request: Request) {
  return Response.redirect(new URL("/new-path", request.url), 302);
}

Live 302 mock endpoint

Point your app, tests, or retry logic at this free public URL to reproduce a real 302 response (CORS enabled, optional ?delay=ms up to 5000).

https://castov.com/api/mock/302

302 vs similar status codes

Frequently Asked Questions

What does HTTP Status 302 mean?
The requested resource resides temporarily under a different URI. Future requests should continue using the original URI.
Why am I getting a 302 status code?
Used for temporary maintenance redirects, landing page AB tests, and authenticated session gateways.
How do I fix a 302 Found error?
Verify whether the redirect should be temporary or permanent (301) for SEO indexing.
What is the difference between 302 Found and 301 Moved Permanently?
301 is permanent: browsers cache it and search engines transfer ranking signals to the new URL. 302 is temporary: the original URL stays indexed.
What is the difference between 302 Found and 307 Temporary Redirect?
Both are temporary. 302 allows clients to switch POST to GET; 307 guarantees the same method and payload are re-sent.
What is the difference between 302 Found and 303 See Other?
303 explicitly tells the client to follow up with GET (Post/Redirect/Get). 302 is ambiguous about the method for historic reasons.
How can I test how my app handles a 302 response?
Send a request to https://castov.com/api/mock/302 — it returns a real 302 Found response with CORS enabled. Add ?delay=2000 to simulate a slow server.

Other 3xx status codes

Browse the full HTTP status codes directory or troubleshoot terminal errors in the Error Fix Encyclopedia.