Skip to main content
Guide· NodSEO Team

What Is a Redirect?

A complete guide to HTTP redirects — what they are, how they work, and when to use each type. Covers 301, 302, 307, and 308 status codes with practical examples.

A redirect tells browsers and search engines that a page has moved to a new URL. Instead of showing a 404 error, the server sends a 3xx HTTP status code that automatically forwards the visitor to the new location.

Redirects are one of the most common tasks in website management. You need them when you change URLs, consolidate pages, migrate to a new domain, or restructure your site architecture.

How redirects work

When a browser or crawler requests a URL, the server responds with an HTTP status code. A 200 OK means the page loaded successfully. A 3xx status code means the resource has moved.

The response includes a Location header that specifies the new URL. The client (browser, crawler, or tool) then makes a new request to that URL. This can happen multiple times in sequence, forming what’s called a redirect chain.

GET /old-page HTTP/1.1
Host: example.com

HTTP/1.1 301 Moved Permanently
Location: https://example.com/new-page

The browser automatically follows the redirect and loads the new page. The visitor usually sees the final page URL in their address bar.

Types of redirects

301 Moved Permanently

A 301 redirect tells search engines the page has moved permanently. This is the most common redirect type and passes approximately 99% of link equity to the new URL.

Use a 301 when:

  • You’ve permanently changed a URL
  • You’re migrating to a new domain
  • You’re consolidating multiple pages into one
  • You’ve changed from HTTP to HTTPS

302 Found (Temporary Redirect)

A 302 redirect tells search engines the page is temporarily available at a different location. Search engines typically keep the original URL in their index.

Use a 302 when:

  • You’re temporarily redirecting during maintenance
  • You’re A/B testing different page versions
  • You’re showing different content based on location or device

In practice, many servers use 302 when they mean 301. Google has stated it will sometimes treat a 302 as a 301 if it detects it’s permanent, but this is unreliable. Always use 301 for permanent moves.

307 Temporary Redirect

A 307 is the HTTP/1.1 version of a 302. It guarantees the request method won’t change — the browser will make the same type of request (GET, POST, etc.) to the new URL.

Use a 307 when:

  • You need to preserve the request method during a temporary redirect
  • You’re redirecting POST requests that should not be automatically resubmitted as GET

308 Permanent Redirect

A 308 is the HTTP/1.1 version of a 301. Like 307, it preserves the request method. Most SEO practitioners use 301 instead, since 308 has limited browser support and the practical difference is negligible.

Common redirect scenarios

Domain migration

When moving from old-domain.com to new-domain.com, you need a wildcard redirect that forwards every URL:

old-domain.com/* → new-domain.com/*

This requires a server-level redirect rule (Apache .htaccess, Nginx config, or Cloudflare redirect rules).

URL restructuring

If you change /blog/post-title to /articles/post-title, set up a 301 from the old URL to the new one. This preserves any backlinks pointing to the old URL.

HTTP to HTTPS

Redirect all HTTP traffic to HTTPS with a single wildcard rule:

http://example.com/* → https://example.com/*

WWW to non-WWW (or vice versa)

Pick one canonical version and redirect the other:

www.example.com/* → example.com/*

Redirect chains and loops

A redirect chain happens when one redirect points to another redirect. For example:

/page-a → 301 → /page-b → 301 → /page-c

Search engines follow chains but prefer direct redirects. Chains slow down crawling and can cause equity loss. Keep chains to 1 hop maximum whenever possible.

A redirect loop is when redirects point back to each other:

/page-a → 301 → /page-b → 301 → /page-a

This creates an infinite loop. Browsers show a “too many redirects” error. Search engines will not index pages stuck in loops.

Redirects and SEO

301 redirects pass nearly all link equity. Google has confirmed this, but it’s still best practice to update internal links to point directly to the final URL.

Crawl budget

Every redirect consumes crawl budget. For large sites with thousands of URLs, unnecessary redirects can delay crawling of important pages.

Indexing

Google will generally index the final destination URL of a 301 redirect. With 302 redirects, Google may keep the original URL in its index, which can cause confusion about which page to rank.

Testing redirects

The simplest way to test a redirect is to use your browser’s developer tools. Open the Network tab, visit the URL, and check the response status code and Location header.

For bulk testing, use the NodSEO Redirect Checker to trace full redirect chains, check status codes, and identify issues like chains or loops.

FAQ

Do redirects affect page speed?

Each redirect adds one additional HTTP request-response cycle. A single redirect adds roughly 50-100ms of latency. Multiple redirects (chains) compound this. For mobile users on slow connections, this can be noticeable.

Can I have multiple redirects?

Yes, but keep chains short. If you need to redirect /page-a to /page-b and /page-b to /page-c, redirect /page-a directly to /page-c instead of chaining them.

Google has said 302 redirects pass link equity in some cases, but this is inconsistent. If you intend a permanent redirect, always use 301.

How do I check if a URL is redirecting?

Use the NodSEO Redirect Checker or run curl -I https://example.com/page in your terminal. The response will show the status code and Location header.

Related Tools

Related Guides

Related Comparisons

Stay updated

Get new guides and tool updates. No spam, unsubscribe anytime.

By subscribing, you agree to receive occasional emails from NodSEO. You can unsubscribe at any time. See our Privacy Policy.