The 301 Redirect: How To Change Your Website Address Without Losing Search Rankings

    by Dharmesh Shah

    Date

    November 15, 2006 at 11:07 AM


    Along the lines of one of my prior articles, “Understanding RSS: A Guide For The Insanely Busy Executive” this article is intended primarily for non-techie types that want to get a better handle on how to correctly change a website address without losing “link love” (the value you build from a search engine optimization perspective for inbound links).  If you happen to be a techie and have wandered into this article, that’s fine too.  You can bookmark this article for later use as it will be a convenient way for you in the future to explain to business people (the non-techies) how the whole redirection thing works and why a 301 redirect is different from a 302 redirect.  It’ll save you 10 minutes of your life that you’ll never get back.  You’re welcome.

    If you’re the non-techie type, or just haven’t been exposed to the whole redirection thing yet, read on.

    Friends, I’ve Moved – Here’s How To Find Me

    At some point in the evolution of your website (be it your business website, a blog or anything else), you may find it necessary and/or desirable to change your website address.  A perfect example of this is if you start off with a blog on blogspot.com like this:  yourcompany.blogspot.com.  Let's say that you then later decide to acquire a “real” domain name and put your blog on it’s own domain like this:  yourcompany.com.  I’ve written before about why it’s a bad idea to use a sub-domain like yourcompany.blogspot.com if you’re serious about your business blogging.  You can read that article here: “Why Your Business Blog Shouldn’t Be On BlogSpot.com”.

    There are two basic ways to effectively implement a “forwarding address” when you change the name of your website.  There’s the easy way, and there’s the right way.

    302 “temporary” redirect

    First, the easy way:  When configuring the output of a website (which is basically HTML), it is possible to add meta-data to the output that tells the world that the content they were looking for is no longer here but actually over there.  This is called a “302 redirect” or also known as a “temporary redirect”.  The effect of this type of redirect is simple to understand.  Any users that try to access your old website are automatically forwarded to the new website.  So, in theory, you shouldn’t really lose any visitors.  The real-world equivalent to this is posting a sign on your front door that says “Moved to 456 Main Street, Boston, MA”.  It is understood that when visitors come and “see” this sign, they are magically teleported to your new address.  Nice and simple, right?  Not so fast.  One important point here is that when the same visitors need to visit you again, they still go to your old house, only to be teleported again.  Why?  Because they’re not sure if you’ve actually permanently moved, so they keep checking the old house, just to be safe.

    The major problem with the 302 (temporary) redirect is that the search engines don’t accept it as a valid address change.  The reasons for this are somewhat complex and convoluted but they don’t really matter to you anyways.  You’re going to have to trust me on this (or do your research).  Here’s what happens:  Let’s say that over some period of time you manage to get about 100 links from various websites to yourcompany.blogspot.com (your old address).  This is great.  Having these “inbound links” is an important factor in driving your search rankings.  Now, you change your address to yourcompany.com.  What happens?   Well, as far as Google (and the other engines) is concerned, yourcompany.com is a net new site with zero inbound links.  Seriously?  Yes, seriously.  Though it is the same website, Google will not give you credit for the inbound links to the old address – as long as you’re using a 302 “temporary” redirect.  Actually, this loss of link love is your best case scenario with a 302.  In your worst case scenario, you can actually get banned from the search engines for doing a redirect the “wrong” way.  The reasons for this are also complicated (but well documented).  There were some big examples of sites getting banned for this kind of thing back in 2004.  For now, let’s assume that the worst that’s going to happen is you’re going to lose all your link love, and hence your search engine rankings.  How do you avoid this?  I’m glad you asked.

    301 “permanent” redirect

    The 301 redirect is a lot like it’s cousin the 302 redirect, only it’s permanent.  Well, it’s really not permanent (because clearly, you could change it again if you wanted to), but it is designated as being permanent.  Here’s the real-world analog to this.  Let’s say, once again, that you have now moved to “456 Main Street, Boston MA”.  This time also, you leave a sign on your old front door, but it says:  “Permanently Moved to 456 Main Street, Boston MA – UPDATE YOUR ADDRESS BOOK”.  The net effect is that visitors that come to your old house still get magically teleported, but they also update their address books, so they don’t repeat that mistake again.  Back to the real Internet example.  When you setup your website with a 301 permanent redirect, you are telling Google to update it’s index and are essentially saying:  “Hey, I had this website over here, but it’s now over there – update all the inbound links in your index”.  Thankfully, Google (and just about every other search engine that matters) will respond obediently.  You get to keep all that link love you worked so hard to get.  Your new site starts off where the old one left off.  Problem solved, right?  Not so fast.

    Now that you understand the difference between a 301 and a 302 (301=permanent, 302=temporary), it’s important to know that it’s not always possible to actually implement a 301 redirect based on the software you are using for your website.  A really important example of software that doesn’t (currently) support a 301 redirect is Google’s Blogger (blogspot.com).  So, if you’re building a ton of link love on yourcompany.blogspot.com, I’d recommend getting a “real” domain name before you do too well.  Otherwise, you’re just going to start from scratch again unless Google changes its errant ways.

    That’s it.  Hopefully, you won’t have to change website addresses all that often, but if you do, keep your fingers crossed that you’ll be able to use a 301 permanent redirect (or make sure you are using a platform that supports it).  Otherwise, you’ll probably have to climb the search rankings hill all over again.

    Have questions, thoughts, war stories?  Would love to hear them.  Leave a comment.

    -Dharmesh Shah.

    SUBSCRIBE TO HUBSPOT'S MARKETING BLOG

    Join 280,000+ fellow marketers! Get HubSpot's latest marketing articles in your inbox. Enter your email:

    Search Inbound Hub

    Subscribe to Marketing Articles by Email

    Subscribe by RSS

    Follow HubSpot

    Call Us: 1-888-HUBSPOT