There are multiple ways to redirect a webpage or an entire website, the two main ways being either a 301 or 302 HTTP response code.
Choosing the right one for the appropriate situation is important for SEO because it sends a signal to Google about how to respond to the redirected webpage, including whether to consider it as canonical.
While Google is constantly evolving how it handles signals, that provided by 301 and 302 response codes has not changed.
In this guide, you’ll learn what 301 and 302 redirects are for, when each one is used, how they impact SEO, and more.
HTTP Response Status Codes
When a browser requests a webpage from a server, the server sends a response to the browser to tell it if the request was successful.
That response is called an HTTP Response Status Code.
The response code tells the browser the status of the request for a webpage.
There are five kinds of HTTP Response Status Codes:
- Information responses.
- Successful responses.
- Redirection responses.
- Client error responses.
- Server error responses.
What Are 301 And 302 Redirects?
A redirect response status code is a message from the server to the browser, telling the browser that the webpage no longer exists at the requested URL.
The redirect response code also informs the browser that the requested webpage has moved to another URL and that the server is now redirecting the browser to the requested webpage at the new location.
You might want to redirect a page for a variety of reasons, including:
- Choosing the canonical URL between WWW and non-WWW.
- You have a new website or page.
- Forcing the browser to use HTTPS when it visits using HTTP.
- You’re fixing a webpage and want users to go to a different page while the old one is under construction.
The purpose of the redirect decides which kind of redirect to choose.
Choosing the wrong option could impact your SEO.
Choosing the correct redirect guarantees that you’ll at least maintain your current rankings.
What Is A 301 Redirect?
A 301 redirect sends the message to search engines that a website or page has been moved permanently.
Permanent means about a year or longer. After a year, check to see if people are still being redirected to your site.
If they are, figure out where they’re coming from and try to fix the source before you cancel the redirect.
Google’s John Mueller recently recommended keeping a 301 redirect in place for at least a year.
When Should You Use 301 Redirects?
Many people use a 301 redirect when they purchase domains that they want redirected to their primary domain.
You might do this with domains that are a misspelling of a brand or variations of the domain name, for example.
It’s also helpful to use a 301 when establishing which domain is your default site: “www.example.com” or just “example.com.”
It’s appropriate to use a 301 if you’ve merged two websites together or have outdated URLs for any other reason, as well.
What Is A 302 Redirect?
A 302 redirect lets search engines know that a website or page has been moved temporarily.
When Should You Use 302 Redirects?
Use this type of redirect if you want to send users to a new site or page for a short period of time, such as when you’re redesigning or updating your website.
Only use a 302 if you’re planning on eventually bringing the old page back or setting up a new one.
You could also use a 302 redirect if you want to test out a new page and get consumer feedback without hurting your rankings from the original page.
How Do 301 & 302 Redirects Impact SEO?
When you use a 301, Google removes the old page from their index, and most value (link equity) from that page is transferred to the new one.
With that said, it’s important to note that anytime you move a page from one URL to another, it will take search engines some time to notice the change – and therefore for you to see any potential impact/change in rankings.
In general, this time period is relatively short.
When used correctly, a 302 redirect will not hurt your SEO efforts.
When you choose this type of redirect, the original page remains indexed in Google and no value (link equity) is transferred to the new URL because Google knows this is just temporary.
Thus, you’ll retain any rankings, traffic value, and authority that page might have.
Where problems tend to arise is when people don’t know the difference between the two, and they choose a 302 to redirect a site permanently.
Essentially, they are creating a new website or page and not transferring over any of the value they’ve accrued over time from the old website or webpage.
That’s why it’s important to understand the difference between a 301 and a 302, and when it’s appropriate to use both.
How To Implement Redirects
“Setting up server side redirects requires access to the server configuration files (for example, the .htaccess file on Apache) or setting the redirect headers with server side scripts (for example, PHP).
You can create both permanent and temporary redirects on the server side.”
If your server doesn’t run on Apache, you’ll have to contact your host for direction.
If your site uses WordPress, you can take advantage of the following plugins that are intended to make redirection as easy as possible:
Redirects Impact Search Visibility
While there are nine redirect response codes that a server can send to a browser, two are used most often: the 301 and 302 HTTP response status codes.
Choosing the correct one for your purposes is critical for SEO.
That means understanding which one to use in order to help Google rank your site where it belongs.
Featured Image: VectorMine/Shutterstock
!function(f,b,e,v,n,t,s) if(f.fbq)return;n=f.fbq=function()n.callMethod? n.callMethod.apply(n,arguments):n.queue.push(arguments); if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0'; n.queue=;t=b.createElement(e);t.async=!0; t.src=v;s=b.getElementsByTagName(e); s.parentNode.insertBefore(t,s)(window,document,'script', 'https://connect.facebook.net/en_US/fbevents.js');
if( typeof sopp !== "undefined" && sopp === 'yes' ) fbq('dataProcessingOptions', ['LDU'], 1, 1000); else fbq('dataProcessingOptions', );
fbq('trackSingle', '1321385257908563', 'ViewContent', content_name: '301-vs-302-redirects', content_category: 'seo ' );