A 301 redirect is a permanent way of moving a web page from its existing URL to a new URL. It automatically takes both users and search engine crawlers from the old location to the new one. This type of redirection is called ‘301’ simply because the HTTP status code ‘301’ means the redirect is permanent.
Why are 301 redirects important?
301 redirects are important from an SEO perspective because a 301 redirect transfers the majority of a page’s link value to the new page. Having high quality sites link to a page is still one of the best ways of boosting a pages rankings. Therefore, it is critical that when a page is redirected that it retains the value of its acquired links.
For example, if you want to change the URL of a page that hundreds of sites have linked to you don’t want to lose the SEO value of all those links. Without a 301 redirect to the new URL, that new page would essentially be starting from scratch. This will result in a decline in keyword rankings and subsequently a decline in traffic to your site.
When should I use a 301 redirect?
You should use 301 redirects whenever you need to permanently move an old page to a new location.
301 redirects should also be used when consolidating multiple pages into one new page. That way the new page will receive the link equity from all of the old pages its pulling content from. Just make sure you are redirecting relevant pages to the new page!
Webmasters also often use 301 redirects when a product is significantly updated and/or removed. This is especially relevant if the newest version of the product is replacing the old version; we want to make sure users and search engines are finding the right destination.
Another common example of 301 redirects is when websites acquire an SSL certificate and therefore need to do a sitewide redirect from http to https. While Google has stated they automatically index https pages, it is still best practice to use a 301 redirect.
How can I implement a 301 redirect?
Implementing 301’s depends on your server type, but we will briefly walk you through the process for the 2 most common ones, Apache and IIS.
For Apache sites you are going to need access to the sites’ htaccess file. In the htaccess file add the following code:
For 1-to-1 redirects (one page being redirected to one other page), all you need to do is add a line of code like this:
Redirect 301 http://www.example.com/1. http://example.com/a
You can do this for as many redirects as you like!
If you have a Wordpress site we recommend downloading the Yoast SEO extension; the code will already be setup and you’ll simply need to add your redirects before the close of the <ifModule>.
For IIS 7 and beyond, we strongly recommend installing the Microsoft-supported URL Rewrite extension. This module makes it easy to implement 301 redirects.
Once the extension is installed go to the ‘IIS Manager’ and then ‘URL Rewrite’.
From there click on ‘Add Rules’, ‘Rule with rewrite map’, and then for the next two dropdowns select ‘Redirect for the rule action and ‘Redirect Demo’ for the rewrite map.
Once this is done, click on ‘Add Mapping Entry’ to bring up another menu.
Under ‘Original value’ type the in the old URL that you want to redirect (you can leave out the domain).
Under ‘New value’, type in the name of the URL you want the old URL to be redirected to. Click ‘OK’ and you are done!
301 redirects permanently change the URL of a page by moving a page to a new URL. This is most often done during site migrations, although it can also be done just to change the URL. 301 redirects are important because they ensure the accumulated link value of the old page is not completely lost during the move to the new page. For 301 redirects on Apache, use the htaccess file; for 301 redirects on IIS, use the URL Rewrite extension.