An Introduction to the Meta tag module in Drupal 8Gurukiran30 Oct, 2019

A website without Meta tags is like a shop without a signboard. With Meta tags, you can showcase what your business/website is about without giving out too many details. Something that can captivate your audience and make them want to click to know more about your website. The Meta tag module in Drupal 8 lets you easily and dynamically create and customize various meta tag elements that can help you improve your search engine optimization (SEO) ranking.

Meta tags have been around for a very long time and play a significant role in optimizing your website for search engines. You can reach your audience organically when you set up meta tags the right way. 

So, how can you improve your Drupal website’s SEO with meta tags while being able to create or modify them as you like? Easy – Leverage the Meta tag module for Drupal 8. 

Meta tag Module for Drupal 8

With the Meta tag module, adding structured metadata about your website is easy. In addition to Meta tags for Keywords and Description, you can also customize content you want to display for each of your social media networks. It supports meta tags for Open Graph Protocol, Twitter Cards, Dublin Core and much more. The inclusion of Drupal Console integrations helps developers to create various custom meta tags too.

Getting Started: Installing the Meta tag Module

Meta tag module requires you to install the tokens and ctool modules.
You will need to download and install the meta tag module from Drupal.org or download it through the composer dependency manager. 

Enabling Meta tag module

Meta Tags

Go to Extend Search for meta tag and enable it. Along with meta tag, you can also install the meta tag extensions such as open graph, twitter cards.

Configuring the Meta tags

Go to Configuration. Click on Meta tag under Search And Metadata.

meta tag moldule

By default, you will get these set of types. Global will be applicable to all your pages. You can create your own Default meta tags for a content type or taxonomy terms and configure it according to your requirements.

Basic Tags

basic tags

These are the foundation tags in meta tags which are very effective in improving your Drupal website’s SEO.

Page title will set the title of the page. While the title tag doesn’t start with "meta", it is in the header and contains information that's very important to SEO.
Description will let you give a brief description of the page. It is used by search engines in the search results to display a brief description about the page.

Advanced Tags

advanced tags

These are optional tags that you can use for improved SEO results.

Geographical tags give the information related to the location. Canonical URL will tell the search engines that the certain URL could have duplicate content and need not be displayed in the search results. Robots will give the option to configure how you want your site links to be seen by the search engines, preventing google translation, disabling the search engine indexing etc. Image is a URL to a unique image representing the content of the page.

Open Graph Meta tags

Open graph meta tags

Open Graph meta tags helps with sharing content on social networks like Facebook, Pinterest, and others. The site name, title, image and description will be the brief content show while sharing. Here you can specify the type of image or video. It is important that you specify the image width and height.

Shefali ShettyApr 05, 2017