Congratulations! You're about to embark on a fun and interesting journey into the world of online marketing. Whether you're trying to sell more products, generate leads, or get more pageviews on your sponsors ads, Search Engine Optimization (SEO) will take you where you want to go.
And, you're using Drupal 6! You've picked a great platform for building your web site. It's widely held that Drupal is one of the best choices if you want to rank well in the search engines. I personally believe that it's hands-down the best possible platform for SEO. I've seen clients triple their traffic within a few weeks of switching from a lesser platform. Believe it—Drupal is the best! But, you already knew that, didn't you? In this chapter, we're going to dive right in and cover some of the top tips for Drupal SEO:
Drupal—which version you should use
How to install 99% of modules
The essential SEO modules that you'll need for your Drupal site
Installing and using the SEO Checklist module
Setting up a Google account
Installing Google analytics and Webmaster Tools on your site
Some great paid tools to help you with your SEO
Note
Helpful web sites:
There are some great resources online to help you along:
www.DrupalSEObook.com: The web site of this book. Visit for additional tips, updates, module suggestions, and to discuss Drupal SEO. The author often participates here so it's a great place to ask questions.
groups.drupal.org/search-engine-optimization
: The Drupal SEO group on www.Drupal.org.
tips.webdesign10.com/drupal-seo
: Another resource for Drupal SEO tips.
The right tools make the project go smoothly. When you decide to SEO your Drupal 6 web site, you'll need the following:
You can download Drupal 6 from two sources:
Drupal.org
: This is where you can get the latest release of the open-source Drupal 6.Acquia.com
: Acquia is a company co-founded by Dries Buytart (the founder of Drupal) and Jay Batson. Acquia has produced a corporate version of Drupal, creatively called Acquia Drupal. Acquia Drupal has some of the better modules pre-installed and provides some great extra services like uptime monitoring, version updates, and advanced support to your installation and modules. Downloading and installing it is free but the services do cost a bit extra—starting at a few hundred dollars per year. That's well worth the extras you get.
Note
Are you running a corporate site and you're not quite up to speed on Drupal? Consider signing up for Acquia's support services. Acquia Network subscriptions provide commercial-grade support and network services for all Drupal 6.x web sites (not just Acquia Drupal) to help you implement Drupal with confidence. Visit http://acquia.com/ for more information.
You can download Drupal 6 from two sources:
Drupal.org: This is where you can get the latest release of the open-source Drupal 6.
Acquia.com: Acquia is a company co-founded by Dries Buytart (the founder of Drupal) and Jay Batson. Acquia has produced a corporate version of Drupal, creatively called Acquia Drupal. Acquia Drupal has some of the better modules pre-installed and provides some great extra services like uptime monitoring, version updates, and advanced support to your installation and modules. Downloading and installing it is free but the services do cost a bit extra—starting at a few hundred dollars per year. That's well worth the extras you get.
Note
Are you running a corporate site and you're not quite up to speed on Drupal? Consider signing up for Acquia's support services. Acquia Network subscriptions provide commercial-grade support and network services for all Drupal 6.x web sites (not just Acquia Drupal) to help you implement Drupal with confidence. Visit http://acquia.com/ for more information.
A module is a community-created plugin that enhances Drupal's core functionality. From XML sitemaps to better page titles, modules are crucial to the search engine optimization of any Drupal site. Installing modules is easy and once you know how to install one, you probably know how to install them all.
Note
For a complete explanation of installing modules, check out the following links: http://drupal.org/node/120641 and http://drupal.org/node/120642.
In the upcoming chapters, you'll come across a lot of Drupal modules. You need to carry out the following steps in order install 99% of Drupal modules:
1. Download the module from http://drupal.org/project/Modules and extract it.
2. FTP to your Drupal site. Drop the extracted module folder into the
sites/all/modules
folder (if that directory is not there then create it).3. Using your browser, visit http://www.yourDrupalsite.com/user and log in.
4. Now visit http://www.yourDrupalsite.com/admin/build/modules/. If you forget this URL, just go to the admin page and click the Modules link.
5. Select the checkbox next to the module that you just installed. If needed, also tic any sub-modules that you just installed.
6. Click on the Save Configuration button. In a couple of seconds, the newly selected module will install itself. Any errors will appear in red.
7. Go to http://www.yourDrupalsite.com/admin/user/permissions and set the permissions for that module so that different roles can use or administer the new functionality that the module has added (not required for all modules).
8. Go to http://www.yourDrupalsite.com/admin and you'll see links to customize the settings of your newly installed module.
If the module isn't working, be sure to read the README.txt
file that came with the module. Sometimes, there are extra steps required to fully install a module.
Note
Drush: The alternative to manual Drupal module installation
If you're comfortable with using the Unix command line, you should consider Drush. Drush is a module created by Moshe Weitzman that provides a command line shell and Unix scripting interface for Drupal. After you install it, you'll be able to use commands like drush dl modulename
and drush enable modulename
to install and enable modules. No trips to drupal.org and no admin screens so it's very fast.
Now that you know how to install modules, there are several that you'll need in order to optimize your Drupal site.
What follows is a list of the non-core Drupal modules you'll use most often for SEO. (Non-core means not included in the base Drupal installation. However, something might be included in Acquia Drupal so check your Modules admin screen first!) We'll cover almost all of these in more detail later in the book. You can either download them all and install them on your site or grab them one at a time as you work on each SEO task. Either way, don't enable them until you're clear what they do and how to configure them. Sometimes, careful setup is required to get the optimal benefit from a module.
SEO Checklist: It provides a checklist with download links and admin shortcuts to most modules and tasks needed during the SEO process.
To download this module, follow this link: http://drupal.org/project/seo_checklist
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/seochecklist
Step-by-step configuration instructions have been provided in this chapter
Note
The SEO Checklist will help you save time
The Drupal SEO Checklist module helps you keep track of the SEO tasks needed for your site. It doesn't do any SEO by itself—it's a checklist that follows along nicely with this book. Links to download and configure most of the modules listed here are built into the SEO Checklist module. It also puts a date stamp on each task as you complete it so it's very handy if you're working on more than one site or you would like to report the work you've done to a boss or client.
Google Analytics: It helps you keep track of visitors.
To download this module, follow this link: http://drupal.org/project/google_analytics
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/googleanalytics
Step-by-step configuration instructions have been provided in this chapter
Page title: It allows you to set
<title>
tags for nodes throughout your site.To download this module, follow this link: http://drupal.org/project/page_title
Note: The Page title requires the Token module to function Download: http://drupal.org/project/token
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/ page_title
Step-by-step configuration instructions have been provided in Chapter 3, On-Page Optimization
Pathauto: It automatically creates search engine friendly URLs based on the title of your content.
To download this module, follow this link: http://drupal.org/project/pathauto
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/pathauto
Step-by-step configuration instructions have been provided in Chapter 3, On-Page Optimization
Path redirect: It helps create proper redirects.
To download this module, follow this link: http://drupal.org/project/path_redirect
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/ path-redirect
Visit the following link in order to create and change paths: http://www.yourDrupalsite.com/admin/settings/build/path-redirect
Step-by-step configuration instructions have been provided in Chapter 3, On-Page Optimization
Global redirect: It fixes some common URL problems when clean URLs and Pathauto are turned on.
To download this module, follow this link: http://drupal.org/project/globalredirect
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/globalredirect
Step-by-step configuration instructions have been provided in Chapter 3, On-Page Optimization
Taxonomy title: It allows you to set
<title>
tags for taxonomy terms throughout your site.To download this module, follow this link: http://drupal.org/project/taxonomy_title
There are no links to the admin site. Set taxonomy
<title>
on each term page.
Meta tags (formerly known as the Nodewords module): It gives you full control of the meta tags on your site, nodes, categories, views, and so on.
To download this module, follow this link: http://drupal.org/project/nodewords
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/user/permissions
Step-by-step configuration instructions have been provided in Chapter 4, More On-Page Optimization
XML Site map: It creates a Sitemaps.org compliant, search engine readable, dynamic sitemap.
To download this module, follow this link: http://drupal.org/project/xmlsitemap
Note: Be sure to get the 2.0 or higher version of the module
Step-by-step configuration instructions have been provided in Chapter 5, Sitemaps
URL list: It creates a plain text sitemap that lists every URL on your Drupal site.
Use it if you can't use the XML Sitemap module
To download this module, follow this link: http://drupal.org/project/urllist
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/urllist
Step-by-step configuration instructions have been provided in Chapter 5, Sitemaps
Site map: It creates a plain text sitemap.
To download this module, follow this link: http://drupal.org/project/site_map
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/sitemap
Step-by-step configuration instructions have been provided in Chapter 5, Sitemaps
Syndication: It offers a web page which centralizes all of the RSS feeds generated by Drupal.
To download this module, follow this link: http://drupal.org/project/syndication
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/content/syndication
Step-by-step configuration instructions have been provided in Chapter 6, RSS Feeds, Site Speed, and SEO Testing
Menu attributes: It allows you to specify some additional attributes for menu items such as id, name, class, style, and rel.
To download this module, follow this link: http://drupal.org/project/menu_attributes
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/content/menu_attributes
Site verification: It assists with search engine site ownership verification.
To download this module, follow this link: http://drupal.org/project/site_verify
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/build/site-verify
Step-by-step configuration instructions have been provided in this chapter
Scheduler: It allows you to schedule when nodes are published.
To download this module, follow this link: http://drupal.org/project/scheduler
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/scheduler
Step-by-step configuration instructions have been provided in Chapter 8, Content is King
Read more link: It allows you to create customized, SEO-friendly Read more links.
To download this module, follow this link: http://drupal.org/project/ed_readmore
To configure this module's settings, follow this link: http://www.yourDrupalsite.comadmin/settings/ed_readmore
HTML Purifier: It helps fix poor html on user generated content.
To download this module, follow this link: http://drupal.org/project/htmlpurifier
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/filters
Step-by-step configuration instructions have been provided in Chapter 9, Taking Control of Your Content
Mollom: It provides spam protection via the powerful Mollom service.
To download this module, follow this link: http://drupal.org/project/mollom
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/mollom
Step-by-step configuration instructions have been provided in Chapter 9, Taking Control of Your Content
There are a few more SEO modules which are optional. Let's have a look at them.
RobotsTxt: It dynamically generates the
robots.txt
file on multiple Drupal installations.Make use of this module if you have multiple sites running off a single Drupal installation and you need different
robots.txt
files for each site
To download this module, follow this link: http://drupal.org/project/robotstxt
Google News sitemap generator: It creates an XML sitemap that meets the specification for Google News.
Use if you're running a news or media web site.
To download this module, follow this link: http://drupal.org/project/googlenews
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/googlenews
Step-by-step configuration instructions have been provided in Chapter 5, Sitemaps
Top Searches: It shows you what people are searching for on your site.
Use if you want to create more interesting content for your site and you want to know what people are looking for
To download this module, follow this link: http://drupal.org/project/top_searches
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/ top_searches
Step-by-step configuration instructions have been provided in Chapter 2, Keyword Research
Open Calais: It provides access to the free OpenCalais tool from Reuters.
Use if you want automatic tagging of your content based on people, companies, organizations, books, albums, places, facts, etc. Typically used for news sites or companies that interact often with the media although others may benefit as well.
To download this module, follow this link: http://drupal.org/project/opencalais
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/calais
Step-by-step configuration instructions have been provided in Chapter 9, Taking Control of Your Content
RDF: It provides RDF functionality and interoperability.
Required for the Open Calais module.
To download this module, follow this link: http://drupal.org/project/rdf
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/rdf
Step-by-step configuration instructions have been provided in Chapter 9, Taking Control of Your Content
More Like This: It provides links to related content based on taxonomies or words you specify.
Works very well with the OpenCalais module
To download this module, follow this link: http://drupal.org/project/morelikethis
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/ morelikethis
Step-by-step configuration instructions have been provided in Chapter 9, Taking Control of Your Content
Autoload: It does not provide functionality directly. It is required by the More Like This module.
To download this module, follow this link: http://drupal.org/project/autoload
Step-by-step configuration instructions have been provided in Chapter 9, Taking Control of Your Content
Google Website Optimizer: It integrates your site with Google's A/B and multivariate tool.
Use if you want to do A/B testing on your Drupal site
To download this module, follow this link: http://drupal.org/project/google_website_optimizer
To configure this module's settings, follow this link: http://www.yourDrupalsite.com/admin/settings/google_website_optimizer
Step-by-step configuration instructions have been provided in Chapter 10, Increasing the Conversion Rate of Your Drupal Web site
Node Hierarchy: It helps create hierarchy in your site which is good for SEO.
To download this module, follow this link: http://drupal.org/project/nodehierarchy
Alinks: It dynamically turns specific words on your site into links.
To download this module, follow this link: http://drupal.org/project/alinks
Digg This: It facilitates links to the popular social bookmarking site Digg.
To download this module, follow this link: http://drupal.org/project/diggthis
Service Links: It adds links to several popular social bookmarking sites.
To download this module, follow this link: http://drupal.org/project/service_links
There are so many good, helpful modules; it's hard to mention them all. Here are a few non-SEO modules that I consider to be a must for any site I'm working on.
Administration Menu: It makes it quick and easy to get to all the admin functions of your web site.
To download this module, follow this link: http://drupal.org/project/admin_menu
Backup and Migrate: It simplifies the task of backing up and restoring your Drupal database or migrating data from one Drupal site to another.
To download this module, follow this link: http://drupal.org/project/backup_migrate
Devel: It makes it easy to generate a bunch of nodes, taxonomies, and users for testing purposes. It has other helpful functions as well.
To download this module, follow this link: http://drupal.org/project/devel
Notify: It sends periodic emails with details of all changes to a site.
Use if you want to review all posts, forums, or comments posted to your site. Great for responding to comments as they happen.
To download this module, follow this link: http://drupal.org/project/notify
Search 404: Instead of a file not found error if a page is missing, it does a search on the keywords in the URL to show possible matches.
To download this module, follow this link: http://drupal.org/project/search404
Note
PHP memory limits and module installation
If you install a lot of modules in Drupal then you may come across the dreaded "White Screen of Death". It often occurs when you visit the Administer | Modules page; you'll see nothing but a white screen. This means that PHP—the language that Drupal is written in has run out of memory. There are several ways to increase the allotted memory. The easiest is to add the line php_value memory_limit 32M
to your .htaccess
file in the Drupal root. You can adjust this to 48M, 64M or even higher, but 32M typically works fine and conserves memory. Don't just max it out as that's the amount of memory that Drupal will use for each visitor and it adds up quickly, especially on shared servers. There are other options if this doesn't work. To find out more, visit http://drupal.org/node/31819.
The Drupal SEO Checklist module is the first one that I install when I begin working on a site. Carry out the following steps to download and install the Drupal SEO Checklist module:
1. Download the SEO Checklist module from the following link, http://drupal.org/project/seo_checklist and install it just like a normal Drupal module. Refer to the earlier part of this chapter for step-by-step module installation instructions.
2. Visit the following link, http://www.yourDrupalsite.com/admin/settings/seochecklist or go to your admin screen and click on Administer | Site configuration | SEO Checklist link. Then, you'll be able to see the SEO Checklist admin page screen, as shown in the following screenshot:
3. Find out which modules you already have installed by clicking on the Check for already Installed Modules button. It will check off any modules you've already installed.
4. Go through each section of the SEO Checklist admin page installing each module or completing each task. Be sure to check off each item as you go and click the Save button.
While it's not necessary to install this module, it will save you hours of research and hunting down the modules you need for proper SEO.
Google is the undisputed leader in search. One way that they stay on top is by providing tools to help web site owners manage their sites. Among other things, they've created Google Analytics, Google Webmaster Tools, and Google Site Optimizer—all three essential to a good SEO campaign. Oh! And they're free. To access all this SEO goodness, you'll need to set up a Google Account.
Note
If you're doing SEO for more than one company, keep them all separate. Set up a Google Account for yourself plus one for each client. If a client has more than one web site, put them all under that client's account. With many of Google's services, like Analytics, you can assign yourself as administrator of each account so you can access everything with one login. Thanks, Google!
Carry out the following steps to set up a Google account:
2. Fill out your information. Be sure to use a valid email address.
3. Read the Terms of Service and then click the I accept. Create my account. button.
4. You'll see a screen that says, In order to verify that the email address associated with your account is correct, we have sent an email message to yourname@yourDrupalsite.com. To activate your Google account, please access your email and click on the link provided.
5. You will receive an email with the subject Google Email Verification and with a link in the body to verify your account. Click on the link.
6. You should see the message, Email Address Verified.
Be sure to save your login in a safe place. You'll need it each time you access one of Google's services.
In bygone years, people tracked visitors on their web site using server logs. While this is still accepted practice, it's difficult and time consuming to access enormous log files to figure out what's going on with your site. Several years ago, companies started releasing tools to make that process easier. They called their products Analytics.
Analytics packages help you track visitors on your web site—where they came from, what they do while on your site, where they are in the world, and if they bought your products or filled out your forms. It works by installing a small piece of JavaScript code in the footer of your site that pings a server every time a visitor loads a page. You could do this yourself but you'd have to process, filter, and store all that data on your own. A good analytics program is easier, faster, more robust, and in many cases free.
A good analytics program will help you learn which online marketing initiatives are cost effective and see how visitors interact with your site. With that information, you can make informed design improvements, drive targeted traffic, and increase your conversions and profits. Analytics won't make the tough decisions for you—they will give you the data you need to make those decisions.
Note
A few common question that analytics can help answer are as follows:
How many unique visitors did I get over the last month?
What is my conversion rate?
How can I improve the visitor experience on my web site?
Why isn't anyone buying my product?
Are the negative comments on my blog affecting my sales?
How many sales came from Adwords vs. my SEO campaign?
Are visitors engaged by my front page or turned off?
It's important to install analytics as soon as possible, so that you can start to accumulate data about your site visitors. The more data you have, the better the reports and decisions you will be able to make. Depending on your site traffic, it may take weeks or months before you have enough meaningful data to put to use improving your site.
While you only need one analytics program, two will allow you to compare results and be sure that your stats are relatively in sync with each other. Different programs track data in different ways. If they're inconsistent then it could reveal a problem that needs to be fixed on your site.
There are dozens of analytics packages out there and it's hard to beat Google's free suite which is simply called Google Analytics. It's easy to install, quick to get started, and has easy-to-read charts. Yet, it boasts very powerful features like advanced segmentation, customizable reporting, and industry benchmarking.
When using Google Analytics with Drupal, it's even better. It's easy to install, configure and test thanks to the Google Analytics module. The Google Analytics module was first created by Mike Carter and is now maintained by Alexander Hass. Thank you, gentlemen!
To create a Google Analytics account and install it on your Drupal site, carry out the following steps:
1. Visit http://www.google.com/analytics and click the Sign Up Now link.
2. Log in using your Google account.
3. Fill out your web site information.
Web site URL: |
Put the full URL of your site. If you use the www, then include it. |
Account Name: |
Google automatically enters the URL but that is often not the right choice. If you will ever have more than one web site that you track with Google Analytics then use an account name that is a bit more descriptive, such as your organization's name or even your name. |
Time Zone Country: |
Enter the country that your web site serves. For example, if your company serves Texas but you host your site in the UK, put United States as the country. |
Time Zone: |
Time zone will influence the dates and times that the analytics will report the traffic data from your site. You'll probably select the time zone that you work or live in. |
4. Click on Continue and fill in your contact information.
5. Click on Continue. Here you'll read and agree to the User Agreement. You'll also notice that you're opted in to anonymously share your Google Analytics data. According to Google, Shared data will be used to improve the services we provide you and will help create more powerful features for you to choose from. There are two levels of sharing.
With other Google products only |
It will only share your data with Google. This is more private and still gives you access to the enhanced features that may come out in the future. |
Anonymously with Google and others |
It will share your data more widely. Any identifying information about your site is removed and then it's mixed in with thousands of other sites' data. If you opt in at this level then you'll be able to benchmark your site with other sites in your industry. This can be helpful to see how you're doing compared to your competition. |
6. Finally, click on Create New Account. You're done!
7. Now install the Google Analytics module. It installs normally like any other Drupal module. See earlier in this chapter for step-by-step module installation instructions. Here's the short version: Download the module, drop it into your
/sites/all/modules
folder, go to /admin/build/modules, and turn it on.
8. To configure the module, point your browser to www.yourDrupalsite.com/admin/settings/googleanalytics at the top of the page and you will be able see a screen similar to the following screenshot:
10. Copy and paste your site's UA number into your Drupal site. (Don't use mine! Get your own!) If you don't see this, click the Analytics Settings link, located at the upper left corner.
11. Under User Specific Tracking Settings, make sure that Users cannot control whether they are tracked or not option is selected. This makes sure that you're tracking all your visitors and they can't turn off the tracking.
12. Under Role specific tracking settings, you will have a few options. For most sites, you want to check everything except the authenticated user option, as shown in the following screenshot:
Note
Role specific tracking settings is one of the best things about the Google Analytics module. One of the common problems with Google Analytics is that it tracks everything that happens on your site—even your own activity. So, if you visit your site a lot (which you probably should) then you'll skew your Analytics. Telling Drupal to not track admin users will dynamically show or not show Google's tracking code depending on if a user is the site admin. There are many uses for this. Say you don't want to track any of your company's users. Just give them a custom account type (like staff) and deselect the checkbox in the Google Analytics module. Clean, easy, and works like a champ!
13. Except for advanced needs, the rest of the settings should be left as the defaults. Click on Save configuration. You're done!
Note
Under Advanced settings, there is a field called Custom JavaScript Code. DO NOT put your Google code there. If you've put your Google account information at the top of the admin page then the module will write all the code automatically. The Custom JavaScript Code field is for special code snippets that are added to the tracking code (refer to drupal.org/node/248699). If you put the full code there then you will track every user on your site twice. Not good!
Google's help pages say 'Once you've correctly installed your tracking code, you should allow up to 24 hours for data to appear in your account'. Check back tomorrow and you should see some data. It starts to get really interesting when you've accumulated several months worth of data. Be patient—it's well worth the wait.
Yahoo! recently launched their own analytics package called Yahoo! Analytics. It's getting good reviews as an alternative to Google Analytics. As of this writing it's only available to Yahoo!'s search and display advertisers. For more information visit the following link: http://web.analytics.yahoo.com/.
If you've got a site that shows up in Google then you need a Google Webmaster Tools account. The Google Webmaster Tools provide you with detailed reports about your pages' visibility on Google. It's one of the most direct ways that you can communicate with Google about your site. It allows you to upload an XML sitemap, see if there are any problems with your site and fix them. It even lets you control the Google spider so that it doesn't drag your site down with constant visits.
To use the tool, you need to verify your site. Fortunately, there is a great module called the Site verification module that helps you verify your site with the search engines. It was created and is maintained by Dave Reid. Thanks, Dave! You'll always be verified in my book!
Carry out the following steps to verify your site with Google:
1. Go to http://www.google.com/webmasters/tools and sign in using your Google account.
2. Type the URL of your web site in the empty box, named Dashboard, and click on Add Site. Your site is now added and it needs to be verified.
3. Click on the Verify link, located next to your site name, as shown in the following screenshot:
Note
You could also chose Add a meta tag and the Site verification module can handle that as well. Either way works equally well.
5. Copy the filename provided, as shown in the following screenshot:
6. Now, install the Site verification module. Refer to the earlier part of this chapter for the step-by-step module installation instructions.
7. Go to http://www.yourDrupalsite.com/admin/build/site-verify/add/google. You'll see a screen similar to the following screenshot:
8. In the Verification file field, paste in the filename that you got from Google and click on the Save button.
9. Test the URL. In your browser, open the following link: http://www.yourDrupalsite.com/<nameofspecialGooglefile.html>. You'll be able to see a screen similar to the following screenshot:
Now that your site is verified with Google, you can take advantage of all the great features that Google Webmaster Tools has to offer. Here are a few to which you should pay particular attention.
Depending on how you set up your .htaccess
file (refer to Chapter 7, robots.txt, .htaccess, and W3C Validation), you can access your Drupal site using a www
or not. For example, http://www.yourDrupalsite.com/ or http://yourDrupalsite.com/ both will point to the front page of your site. This is not ideal because Google may treat those two URLs as two different pages and assume they contain totally different content. You'd actually be competing with yourself in Google and that's not a good thing.
Fortunately, you can fix this problem using the preferred domain setting. The preferred domain is the one that you would like used to index your site's pages and to have show up in Google. If you specify your preferred domain as http://www.yourDrupalsite.com and Google finds a link to your site that is formatted as http://yourDrupalsite.com, they'll treat that link as if it was http://www.yourDrupalsite.com. In addition, Google will take your preference into account when displaying URLs in the search results.
If you are on a slow server, you may want to consider asking Google to be a bit more considerate about how much data it grabs from your site at a time. This is called the crawl rate. It doesn't effect how often Google visits, just how many pages they ask for at a time. It can be very helpful if you're experiencing a server slowdown.
Carry out the following steps in order to set the crawl rate in Google Webmaster Tools:
1. On the Webmaster Tools Dashboard, click the URL for your Drupal site.
2. Click Settings from the left hand menu.
3. In the Crawl rate section, select Set custom crawl rate.
4. Adjust the slider to change the crawl rate, as shown in the following screenshot:
Did you ever wonder how all those pages got into the search engines in the first place? There's a magic search engine genie that flies from server to server waving a magic wand; not really but close. Actually, there is a computer program called a crawler (or sometimes a spider or robot or'bot) that lives on the search engine's servers. Its job is to surf the Web and save anything it finds. It starts by visiting sites that it already knows about and after that, follows any links that it finds along the way. At each site that it visits, it grabs all the HTML code from every single page it can find and saves that on its own servers.
Later, an indexing server will take that HTML code, examine it, parse it, filter it, analyze it, and some other secret stuff (a lot like waving that magic wand). Finally, your site is saved into the search engine's index. Now, it's finally ready to be served up as a search result. Total time elapsed? About two minutes.
One important thing to note here is that search engine crawlers follow the same links that you do. That means that if you can't click the link, then there's a good chance that the crawler can't click the link either. Fortunately Google does a great job of following JavaScript links, but if you're using JavaScript for your Drupal navigation menus then chances are good that other search engines can't see much past your front page. That's where some creative techniques can really come in handy. Breadcrumbs to show navigation or an XML sitemap (refer to Chapter 5, Sitemaps) can help the crawler find out where to go next. That's why those tools are sometimes called spider food.
Here are a handful of useful tools that are not quite free. They are useful and have a place in every good SEO bag of tricks.
Eye-tracking studies show you where people are looking while they're on your web site. Dries Buytart, the founder of Drupal, showed one during his 2008 State of Drupal address at the Boston DrupalCon. The heat map shows where the users look in the first five seconds after landing on Drupal's main administration page. The red X's show where the users clicked, as shown in the following screenshot:
With CrazyEgg, you can do something similar on your own web site. Although it can't track your visitors' eye movements, it can show a heat map that shows you where your visitors click. This is another one of those tools that you should install and let run for a few weeks or months so that you can collect some useful data.
The Crazy Egg tool costs $9 per month. To try it yourself, visit their website at www.CrazyEgg.com.
Mint is an extensible, self-hosted web site analytics program. Visits, referrers, popular pages, and searches can all be taken in at a glance on Mint's flexible dashboard. It's not as powerful as Google Analytics but it's very simple to use and hosted right on your own site, so it's fast and timely. The following screenshot shows how the Mint tool works:
Mint costs $30 per site. To try it yourself, visit their website at www.haveamint.com.
There are several other great free tools you can use. Let's go ahead and have a look at them.
Why would I possibly need two browsers? One of the great features of Drupal is that it knows if you're logged in and will show different screens when you're the admin of the site than it would if you're an anonymous visitor. For example, you may have noticed an Edit link on each node of your site when you're logged in as the admin.
This little trick is cookie-based. Browsers don't share cookies so you can be logged in to your site on Firefox and show up as an anonymous user in Safari. With two browsers installed, you can make changes as the admin on one browser and see those changes as an anonymous visitor on the other.
Another helpful tool is the Google Toolbar. Google Toolbar gives you some very helpful tools like a Google search box and the Google Pagerank indicator. Visit any page on the web and the toolbar will tell you the Pagerank of that page. Currently, the Google Toolbar only supports Firefox and Internet Explorer. The following screenshot shows the Google Toolbar for Mozilla Firefox:
PageRank is a very important factor which needs to be taken into consideration for the Search Engine Optimization of your site.
PageRank is a number between zero and ten that expresses Google's view of the importance of a web page. Important pages receive higher PageRank and are more likely to appear at the top of search results. Links pass PageRank value from one page to another. It's sometimes called link juice. A link from an important site passes more link juice than a link from a lesser site.
Assuming that you're using Firefox, adding the SEO for Firefox plugin to your browser will add a plethora of great SEO-related tools to use right in your browser. When you view search results in Google, this nifty plugin overlays useful data about each site in the results. For example, it will show you the PageRank, domain age, and how many backlinks it has, as well as how many links from popular web sites like dmoz, twitter, del.icio.us, and Digg. This can be invaluable when you're doing keyword research (refer to Chapter 2, Keyword Research). Download it from the following link: http://budURL.com/seoforfirefox.
Google isn't the only search engine that offers some great tools. Yahoo! is one of the few search engines that will provide you with a list of all the links you have coming into your site. Just point your browser at http://siteexplorer.search.yahoo.com/ and put in your URL. You can even add a badge to your site that tells you how many in links you have, as shown in the following screenshot:
In this chapter, we covered all the tools you're going to need for Drupal SEO. From Drupal and all the great modules available for SEO to setting up a Google account, this chapter is the foundational to the rest of this book. At this point, you should have:
A Drupal site set up and installed
A good grasp of how to install a Drupal module
The SEO Checklist module installed
A Google account
A Google Analytics account
A Google Webmaster Tools account
A preferred domain and crawl rate set in Google
Two browsers installed
The Google Toolbar and the SEO for Firefox plugin.
In the next chapter, we explore keyword research—the most fundamentally important part of your SEO campaign.