301 redirect

This is a lengthy, instructional post outlining typical SEO problems and solutions with sites that have gone through several re-designs. OK, now that I’ve got your attention, let’s get down to business.  If your site is more than a few years old, chances are it’s been through a fair share of changes.  You’ve probably had three different designs, multiple programmers or web shops working on it.  You probably went from PHP to .NET, and back to PHP again, and you added a blog from WordPress and migrated all of the static content there too.  You added a boatload of pages, and got rid of just as many after marketing went through their nineteenth change in messaging.  Sound familiar?  Right – that’s why your site is…well….not showing up in Google as frequently as it should be.

Read the rest of this entry »

Updated 3/1/2011: There are tons of people re-designing, re-tooling or completely re-vamping their websites right now.  With all of the new technology, easy set-up and programming-free options out there (not to mention cost-effective), many businesses are taking advantage.  The problem is that SEO is still an afterthought.  We still hear things like “we’re re-building the site right now, but we will contact you after that so we can start the SEO work”.

Woah there!  But we can still do some SEO work even while the site is under redesign or redevelopment.  Here are a few tips:

1.  Do your keyword research up front. While you are putting together content, page structure, or trying to figure out what CMS you are going to use, now is the time to start keyword research.  You want to determine the 5-10 main keywords that you will want to target your site for and methodically build pages, content and links around them.  Then, determine the secondary set of keywords that are longer-tail in nature, but support the main keywords.  As a rule of thumb, start with words that are not overly-competitive.  Choose words that are perhaps more long-tail vs. head terms (like choose “seo page analysis tool” instead of “seo”) and have smaller search volumes.  High search volume words (i.e. higher than 5,000 searches per month) can indicate healthy competition for that word or phrase.

2.  Keep the architecture simple. No need for 5 and 6 levels of navigation for most sites.  Two is usually good, with 3 for more complex sites with user-generated content or e-commerce.  The idea is that you want most of your pages accessible within 2 clicks.  That means it’s not only going to be easy for human visitors to find your content, but easier for the Googlebot too.  Create an XML sitemap, and determine how you will organize your content. Our strategy is fairly simple – group related content together and create content that Google thinks is related, or that Google would suggest as an alternative search.  (see our architecture sample below).  You can also use footer links kind of like how PEER 1 does here to link out to deeper nested pages.  Always use “clean URLs” and trailing slashes in terms of URL structure – it’s good for SEO.  Also make sure you define your canonical URL, or primary URL, such as “www.site.com” and”site.com”.  Those are considered to be two different websites, and you don’t want Google to determine which one you prefer.

example of site architecture for SEO

3.  Check your inbound links for anchor text enhancements. Our Competitor Analysis report will uncover your inbound link profile and use of anchor text compared to your competition.  You can read how the right anchor text will improve your search engine rankings on our blog.  We get them straight from Yahoo SiteExplorer or Open Site Explorer, and while the new site is under development, you can try to re-target some of these links to the new pages with more descriptive anchor text.

4.  Make sure you re-direct all of the old pages. Many site owners forget this very important step.  Many times when you launch a new site, the old pages are still in Google’s index, but no longer available on your site.  In this case, a search result can have one of these “old pages” and link to a 404 error.  To fix this, you need to do a proper 301 redirect from the old page to the new page, or you can remove the page from Google’s index all together.

Need more help?  Mozy on over to our affordable plans to help you get this done by signing up for our Starter Plan.  No recurring fees, and no commitment.  Easy as pie.

In today’s blog post we will discuss how to implement a proper 301 redirect on Apache or Windows servers from one domain to another. Redirects are technical and we see a lot of sites where 301 redirects are not implemented properly. You might want to do 301 redirects because of a number of reasons: redirecting the non www to www and vice versa, or if you are changing your domain or a file within the same domain.  This is also a great post on ways you can fix your 404 error pages.

Before we enter the technical details, it is important to understand the importance of a 301 redirect from non www to www version of your site (or vice versa). First having two versions of your site can create duplicate content, which may result in your website being penalized by search engines. Secondly and most importantly, when you acquire links it’s always much better to have them pointing at one version of the site versus distributing it among two pages which dilutes the search engine importance to your domain.

301 redirects is the most preferred way of handling duplicate content. Other ways include using the ” rel = canonical” tag (don’t use for cross domain, Yahoo/ Bing still don’t recognize it), blocking files in robots.txt and the meta noindex tag.

Let’s dive into the technical details:

Implementing 301 redirects for an Apache server:

Step 1: To implement a 301 redirect the file we need to work with is the .htaccess file. To access the file you need to go into your FTP and look into the document root.

Step 2: If you can’t see it, enable viewing of hidden files since the .htacess file is hidden. If there is still no .htaccess file present , create one with a simple text editor.

Step 3: Insert this code in the file:

Code example from non www to www:

RewriteEngine On

RewriteCond %{HTTP_HOST} !^www\.example\.com$ [NC]
RewriteRule .? http://www.example.com%{REQUEST_URI} [R=301,L]

Obviously you will need to replace ‘example’ with your own domain name.

Also make sure the Rewrite Engine is turned on, you will just need to turn it on once.

Step 4: Save and Test it!

Implementing 301 redirects for a Windows server:

When setting up a site in IIS, the normal process is to create one account for the site and add both www and non-www versions of the domain name to the host headers for the account. This creates a canonicalization issue;  and the site will then be available at both www and non-www URLs.

Step 1: Get access to the Windows Server navigation Panel. Navigate your way to the Internet Services Manager (Programs — Administrative Tools — Internet Services Manager).

Step 2: Create 2 accounts for the site within IIS: one with the www version of the domain in the host header and one with the non-www version of the domain. All of the site files can be placed in the preferred version and a single page in the other.

Step 3: Right click on the single page you want to redirect FROM and choose Properties. The Properties box will now appear.

Step 4: Change the redirect option to “A redirection to a URL” and type in the new URL in the box provided.

Step 5: Be sure to check the box marked “A permanent redirection for this resource”. If you leave this box unchecked, you will create a 302 (temporary) redirect, which is not permanent or beneficial from an SEO standpoint in this situation.

Step 6: Test it!

Update July 6, 2011 – Doing a www redirect for Front Page

As I see some of the comments below pertaining to Front Page, it was a matter of time before I had to do one for this God-forsaken MS product myself.  Here’s how I did after some trial and error:

1.  First, you have to identify weather you are running Linux or Windows.  This works for Linux.  Apparently, there is an extension called FollowSymlinks which needs to be turned on, as well as Mod Rewrites, so call your host provider for that one.

2.  FP uses several .htaccess files – one in the main directory structure, and 3 other .htaccess files called “super files”.  You will find these other .htaccess files here:

/_vt_bin/.htaccess

/_vt_bin/_vti_aut/.htaccess

/_vt_bin/_vti_adm/.htaccess

3.  Make sure this is at the top of all 4 .htaccess files: “Options +FollowSymlinks” underneath “# -FrontPage-”

4.  Underneath this, add your 301 redirect command:

RewriteEngine On RewriteCond %{HTTP_HOST} ^yoursite\.com$ [NC] RewriteRule ^(.*)$ http://www.yoursite.com/$1 [R=301,L]

Here, I did a 301 from non-www to the www, because for SEO purposes, most people have more inbound links pointing to the www version.

That’s is – this should work!