Metatag - Module

Out of the box, Drupal does not add Metatags to pages, and this is by design, but there is a module to add metatags and it is called metatags!

The first step is to navigate to the metatag download page, select your correct release, and install the module.

But which module to install?  Metatags comes with an austonding 16 sub modules!

The metatags modules are located in the SEO grouping.

Since this is a website and not a semester long college course, we are going to demonstrate and the primary module, Metatag.

This is the metatag module installed.

To configure metatags click the configure link via the modules page or navigate to: /admin/config/search/metatags.

On the Metatag page, you will see three tabs, Defaults, Settings, Bulk Revert.  Lets go out of order and begin with settings.

These are the three primary areas of configuration for metatags.

The settings tab allows you to control which entities get metatags.  By default it is everything, and you do not want that.  It is just a waste of CPU power and bloats the database base.  Many developers will remove the metatags for taxonomy terms and user.

These are the settings that work for this site and they work well.  Click the save configuration button at the bottom if you change anything.

You are probably tempted to click the Advanced settings.  For a basic site, don't.  There are a lot of technical options that aren't well documented.  But you are not going to listen are you?  Good.  The best way to learn is to explore.

Back on the Defaults tab is where you can configure your metatags.  You will see that everything is under Global and to see those Global settings click the Override link.

The red arrow allows you to override the global settings.

Global settings appear on every page.  

There are four main settings:

  • Page Title
  • Description
  • Abstract
  • Keywords

Page title is obvious,  this is the <title>Title page</title> that appears in html.  You can keep the defaults or change the setting.

The default settings are:  [current-page:title] | [site:name].  On this site, we added the word Drupal.

Similar can be done with description, abstract, and keywords!

Wait!  Theres a trick to maximize these settings.  You can add tokens!  To see the available tokens, click the Advance link at the bottom, then click the browse available tokens.

Click the red arrow to see the tokens link.  Click the blue arrow to see the tokens.

Yes, it is odd that tokens, which make metatags really function well is hidden, but Drupal can be odd.
Most of the tokens, which there are many, will not apply, but you should look through them all, especially if you are an expert in search engines.

You can take your tokens and place them in your fields.  You can also add text.

These are the settings used on this site.  Do not use similar settings!  We are not search engine specialists.  We have zero idea if these are working.

If you make any changes, save the page.

When you go to the view source of your page and your metatags are not showing up, clear the cache.  They should show up then.