A 302 Found status code means the page you asked for is temporarily at another address, given in the response’s Location header, and your browser goes there automatically. It isn’t an error. It becomes a problem when a move that should be permanent uses a 302, when redirects loop, or when visitors are sent somewhere they shouldn’t be, such as a login or maintenance page.
What 302 Found means
RFC 9110, section 15.4.3 defines 302 as “the target resource resides temporarily under a different URI”, so the client “ought to continue to use the target URI for future requests”. The server should send a Location header with the other address. For historical reasons a browser may turn a POST into a GET when it follows a 302; MDN notes that browsers do exactly that, and that 307 is the code to use when the method must stay the same.
| Code | Permanent? | Method on the next request |
|---|---|---|
| 301 Moved Permanently | Yes | POST may become GET |
| 302 Found | No | POST may become GET |
| 303 See Other | No | GET (or HEAD) |
| 307 Temporary Redirect | No | Unchanged |
| 308 Permanent Redirect | Yes | Unchanged |
Search engines care about the difference. Google follows a 302 but treats it as only a weak signal that the target should be indexed, and with a temporary redirect it shows the original URL in results (Google Search Central). If a page has really moved, a 302 can keep the old address in Google’s results.
Common causes of a 302
- Redirect code without a status. In PHP,
header('Location: …')sends a 302 unless a 201 or 3xx status was already set (PHP manual). WordPress’swp_redirect()andwp_safe_redirect()default to 302 too. - Server rules written as temporary. An Apache
RewriteRulewith a bare[R]flag,Redirect temp, or nginxreturn 302andrewrite … redirect. - Sign-in walls. Apps commonly send signed-out visitors to the login page with a 302, so a page that should be public can quietly start redirecting after a permissions change.
- Language, region or device redirects that send each visitor to a local version.
- Maintenance and “coming soon” modes that redirect every page to one notice.
- Loops. Two rules that undo each other, such as one forcing https while a proxy forwards http, or one adding a trailing slash while another removes it. Browsers give up and show “too many redirects”.
How to fix a 302 on your own site
- Trace the full chain. Run the address through Monity’s free redirect checker: it follows each hop and shows its status code, Location and headers, and can ask as Googlebot to show what search engines get.
- Decide whether the move is permanent. If it is, change the 302 to a 301, or a 308 if a form or API POST must keep its method. In PHP that’s
header('Location: https://example.com/new', true, 301); in WordPress,wp_redirect( $url, 301 ); in Apache,Redirect permanentor[R=301]; in nginx,return 301. - Point the first URL straight at the last. Googlebot follows up to 10 hops, but every hop costs visitors a round trip.
- Break loops at the source. Find the two rules that disagree. Behind a load balancer or CDN, check that the app knows the original request was https, usually from the
X-Forwarded-Protoheader, before it forces https again. - Keep 302 where it’s true: a login redirect, a short promotion, an A/B test or a page that’s offline for a few days.
Seeing a 302 on someone else’s site?
Usually there’s nothing to do: your browser followed it. If you keep landing on a sign-in page, sign in or check that the link isn’t to a members-only area. If the browser reports too many redirects, clear that site’s cookies and try a private window, since a stale cookie can keep a loop going. If it still loops, the site has to fix it; tell its owner which address you started from.
Is it the server or me?
Most redirects are the same for everyone. Run the address through the redirect checker: if it shows the same 302 and the same target, the server sends it to all visitors. If the checker reaches the page directly but your browser doesn’t, the redirect depends on something about you, such as a cookie, your language settings or your location.
Get alerted when a page starts redirecting
A 302 isn’t a failure code, so the useful check is on the destination. Monity’s uptime monitoring has two kinds of monitor for this:
- Website monitors check each answer’s HTTP status, with JSON and header checks on the response.
- Keyword monitors check for text the page must contain, such as a product name or a heading only that page has. If the page starts sending people to a login or maintenance page, that text is missing and the monitor alerts you.
Checks run every 30 seconds to every hour, depending on the plan (every 5 minutes on the free plan). A failure is checked again 3 and 6 seconds later before an alert goes out by email, Slack, Microsoft Teams, Discord, Telegram, Google Sheets, webhook or app push. Each incident keeps the status, timings, headers, response and a screenshot, so you can see where visitors ended up. The free plan includes 3 monitors.
Related guides: all HTTP status codes, 404 Not Found.