Skip to content

301 vs 302 redirect

Two HTTP redirect status codes with different caching implications. 301 = permanent (browsers cache it and skip the redirect on future requests). 302 = temporary (browsers re-fetch every time). For affiliate redirects, always use 302.

A 301 tells browsers and proxies "this URL has permanently moved; cache the new location and never ask me again." A 302 says "this URL is temporarily elsewhere; check with me every time." For website restructures and SEO, 301 is the right answer because the destination is meant to be permanent. For affiliate redirects and managed URLs, 302 is the right answer because every click needs to flow through the platform.

The full HTTP redirect family. Five status codes matter. 301 Moved Permanently and 302 Found are the two you encounter daily. 303 See Other is used after a POST to send the browser to a different resource via GET. 307 Temporary Redirect is the modern, stricter version of 302 that preserves the request method (a POST stays a POST after the redirect). 308 Permanent Redirect is the same upgrade for 301. In practice 301 and 302 dominate; 307 and 308 are mainly used by APIs.

How caching actually works. A browser that follows a 301 stores the mapping in its cache and, for any subsequent request to the original URL, jumps straight to the cached destination without contacting the original server. Browser caches typically retain 301s for weeks to months. CDNs and ISP proxies cache them too. A 302 is treated as non-cacheable by default; the browser re-fetches the original URL every time. The practical consequence: a 301 you set today is hard to undo tomorrow because every visitor whose browser saw it still has the cache.

SEO implications. For website-to-website restructures (moving /about-us to /about), 301 passes essentially all of the link equity to the new URL. 302 historically passed less, though Google has stated since 2016 that both pass equity in practice. For SEO purposes the choice is mostly about intent signalling: 301 says "this move is permanent, update your index", 302 says "this is temporary, keep the old URL in mind". Neither matters for affiliate redirects because the redirect target should not be indexed in the first place (the managed URL itself is marked noindex).

Why 301 is dangerous for affiliate redirects. Three failures stack. First: a browser that cached your go.yourdomain.com/headphones → amazon.com/dp/... redirect bypasses your platform on every subsequent click, so click counting, bot filtering, and analytics stop seeing real numbers. Second: affiliate destinations change. ASINs get reassigned, products go out of stock, networks change shortlink formats. Cached 301s send clicks to stale destinations forever. Third: you cannot fix the broken destination by updating it in your dashboard because the cached browsers never ask again.

The 302 + no-store pattern. The defensive setup for any managed-URL service is 302 plus Cache-Control: no-store plus Pragma: no-cache. Belt and suspenders. The 302 alone tells well-behaved browsers not to cache; the no-store header tells aggressive intermediate proxies (Cloudflare, ISP caches, corporate proxies) not to either. Every click re-traverses your platform, gets bot-filtered, gets counted, and goes to whatever the current destination is.

Recovering from an accidental 301. If you ever serve a 301 by mistake on an affiliate URL, the damage is hard to fully undo. Server-side you can immediately switch to a 302, but every browser that already cached the 301 will keep skipping the redirect until its cache entry expires (weeks to months, sometimes longer). Practical mitigations: change the URL slug entirely (which forces fresh caching), or wait out the cache window while losing tracking on the cached portion of traffic.

Frequently asked

What is the difference between 301 and 302 redirects?

301 is permanent: browsers cache the redirect and skip it on future requests. 302 is temporary: browsers re-fetch the original URL every time. The difference matters mostly for caching behaviour, with knock-on effects on SEO and on tracking platforms that need every click to pass through.

Should I use 301 or 302 for affiliate redirects?

Always 302. Affiliate redirects need every click to flow through the platform for tracking, bot filtering, and dynamic destination updates. A 301 caches the redirect in the browser, bypasses your platform on subsequent clicks, and is hard to undo because cached browsers keep using the stale destination.

Does Google treat 301 and 302 the same for SEO?

Largely yes. Google has stated since 2016 that both pass link equity in practice. The remaining difference is intent signalling: 301 indicates a permanent move (the new URL should be indexed), 302 indicates a temporary one (the old URL stays in the index). For non-indexable affiliate redirects, this distinction is moot.

Can I change a 301 to a 302 after the fact?

You can change the server response immediately, but every browser that already cached the 301 will keep following the cached redirect until its cache entry expires. That can take weeks or months. The practical workaround is to change the URL slug entirely, which forces a fresh cache lookup.

What happens if I use a 301 for an affiliate link by mistake?

Future clicks from the same browser skip your platform and go straight to whatever destination was cached at the time of the original redirect. Click counting stops, bot filtering stops, and any destination update you make in your dashboard is invisible to those browsers. Set Cache-Control: no-store and switch to 302 immediately, but expect lingering bypasses for weeks.

Have 10 affiliate links? Start monitoring them free.